Thread: Bug report
<b>PGadmin version 1.6.3 release 6112 on windows<br /> from the binary zip file from postgres8.2.5</b><br /><br /> Creatinga sequence by means of the graphical interface works, though a subsequent select nextval() claims he can't find thesequence<br /><br /> the script that is created:<br /><br /><font face="Courier New">-- Sequence: "Uqn7"<br /><br /> --DROP SEQUENCE "Uqn7";<br /><br /> CREATE SEQUENCE "Uqn7"<br /> INCREMENT 1<br /> MINVALUE 1<br /> MAXVALUE 9223372036854775807<br/> START 3<br /> CACHE 1<br /> CYCLE;<br /> ALTER TABLE "Uqn7" OWNER TO live;<br /></font><br/> If I create the sequence without the double quotes<br /><br /><font face="Courier New, Courier, monospace">--Sequence: "Uqn7"<br /><br /> -- DROP SEQUENCE "Uqn7";<br /><br /> CREATE SEQUENCE Uqn7<br /> INCREMENT 1<br/> MINVALUE 1<br /> MAXVALUE 9223372036854775807<br /> START 3<br /> CACHE 1<br /> CYCLE;<br /> ALTER TABLEUqn7 OWNER TO live;</font><br /><br /> The sequence is created and works !<br /><br /> Pascal Van Puymbroeck<br /> ZENONproductions bvba<br /> BELGIUM<br /><br /><br /><br /><br /><br />
Dave Page wrote: > Pascal Van Puymbroeck wrote: >> *PGadmin version 1.6.3 release 6112 on windows >> from the binary zip file from postgres8.2.5* >> >> Creating a sequence by means of the graphical interface works, though >> a subsequent select nextval() claims he can't find the sequence >> > > ... > >> If I create the sequence without the double quotes > >> CREATE SEQUENCE Uqn7 > > ... > >> The sequence is created and works ! The name gets folded to lower case without the quote so I suspect what is happening is that you are not quoting the name in the nextval call correctly. This works: SELECT nextval('"Uqn7"'); To avoid having to use the double quotes at all, stick to names that aren't keywords, and are lower case only, optionally including numbers or _ Regards Dave