Page 1 of 1

serendipity_event_faq PostgeSQL error?

Posted: Tue May 09, 2006 3:35 pm
by vastneonwolf
Just installed this plugin via Spartacus all seemed to be well until I tried to add a category.
Got this error

Code: Select all

Warning: pg_query(): Query failed: ERROR: invalid input syntax for integer: "" in /var/vhost/writehand.org/html/include/db/postgres.inc.php on line 207
Error in INSERT INTO serendipity_faq_categorys (id,parent_id,category,introduction,catorder) values ('', '0', 'Editors', '', '1')
ERROR: invalid input syntax for integer: ""
Followed by what looks like a complete dump of the DB then this.

Code: Select all

INSERT INTO serendipity_faq_categorys (id,parent_id,category,introduction,catorder) values ('', '0', 'Editors', '', '1')
Warning: pg_query(): Query failed: ERROR: currval of sequence "serendipity_faq_categorys_id_seq" is not yet defined in this session in /var/vhost/writehand.org/html/include/db/postgres.inc.php on line 161

Warning: pg_num_rows(): supplied argument is not a valid PostgreSQL result resource in /var/vhost/writehand.org/html/include/db/postgres.inc.php on line 162

Warning: pg_last_oid(): supplied argument is not a valid PostgreSQL result resource in /var/vhost/writehand.org/html/include/db/postgres.inc.php on line 166
Any help would be appreciated.

Re: serendipity_event_faq PostgeSQL error?

Posted: Tue May 09, 2006 4:00 pm
by garvinhicking
Hi!

That'S true, it's a PGSQL issues, which does not treat '' as integers and thus does inproper casting. MySQL ignores this and just uses an auto_increment value there.

I'm sure Falk (the developer of this plugin) catches up on this thread, and I think it shouldn't be too hard to solve this issue. :-)

Best regards,
Garvin

Posted: Thu May 18, 2006 8:07 am
by falk
Today i send a patch to Garvin. I hope i fix this problem. If not, please contact me again.