Search Postgresql Archives

Re: Cursor Issue??

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Here is a further test:

------------------------------------------------------
BEGIN WORK;
DECLARE cursor1 CURSOR FOR SELECT * FROM PARTS;
FETCH FIRST IN cursor1;
INSERT INTO partstemp VALUES (PARTS.QTY, PARTS.LENGTH, PARTS.WIDTH);
CLOSE cursor1;
COMMIT WORK;
------------------------------------------------------

What I get is the whole table put into partstemp.  I just wanted the
one row???
One more question what is the difference between using the term IN vs.
FROM?


---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux