PDA

View Full Version : Help troubleshooting schema.sql and data.sql


jardosa
26-04-2005, 07:40
Hi to all,

Im a newbie here and trying out zabbix version 1.0. Right now Im in the part of populating the postgresql backend with the sql scripts inside create/postgresql. Im receiving this error

error: insert or update on table "functions" violates foreign key constraint "$1"

detail: key (itemid) = (17208) is not present in table items

I searched for solutions to this problem and have found the post of foundation, I tried his solution but this does not fix the data insert error. I checked out the data.sql and found out that this scripts is trying to insert a record into functions table with an itemid of 17208 which does not exist in items table. What should I do? Should I remove the last insert statement to the functions table and If do that will this have any effect in zabbix?

BTW, I downloaded the most recent version and looked into the sql scripts (schema and data) it still has the issues raised by foundation, how come?


Many thanks

Jan ;)

rajeevtomar
11-05-2005, 15:22
I am also having this problem.Could any one throw some light on the error mentioned below:

ERROR: insert or update on table "functions" violates foreign key constraint "$1"
DETAIL: Key (itemid)=(17201) is not present in table "items".


This error I am getting when I am running the command .

cat data.sql |psql -U postgres zabbix

Thanks, Rajeev