Hi,
I'm trying to insert values into the Postgres database and I can't figure out the correct grammar for the "ID" field.
My ID field type is int4 and default value is, nextval('wsckl_id_seq'::text), which will automatically increment the value by 1.
(postgres sort of came up with this by itself).
My current insert string is:
$result=pg_exec($conn,"insert into wsckl values ('nextval('"wsckl_id_seq"'::text)','$arr[1]','$arr[2]','$arr[3]','','')");
and it screams parse error :o(
If I change this -- 'nextval('"wsckl_id_seq"'::text -- into nothing or numeric value, everything works fine, except the ID value gets out of wack. Which I prefer not to do.
Thank You for your assistance in advance.
Petri