By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,401 Members | 820 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,401 IT Pros & Developers. It's quick & easy.

Relation Does not Exists

P: 27
Dear Friends,

I guess the problem I am prosting right now should be quite trivial, but nevertheless I'm experienced with SQL, this does not stand for PostgreSQL.

I have a table with the stucture approx:
Expand|Select|Wrap|Line Numbers
  1.  idorvos | integer                  | not null default nextval(('idorvos'::text)::regclass)
  2. nev     | character varying(255)   | not null
  3.  
And I want to run the query:
Expand|Select|Wrap|Line Numbers
  1. INSERT INTO "orvos" ("idorvos","nev") VALUES (DEFAULT,'TESZT')
...and got the response
Expand|Select|Wrap|Line Numbers
  1. ERROR:  relation "idorvos" does not exist
  2.  
I cannot change the query because it comes from PHPCake

Please tell me what the problem might be.

Thanks
z
Jan 18 '08 #1
Share this Question
Share on Google+
4 Replies


Expert 100+
P: 700
Dear Friends,

I guess the problem I am prosting right now should be quite trivial, but nevertheless I'm experienced with SQL, this does not stand for PostgreSQL.

I have a table with the stucture approx:
Expand|Select|Wrap|Line Numbers
  1.  idorvos | integer                  | not null default nextval(('idorvos'::text)::regclass)
  2. nev     | character varying(255)   | not null
  3.  
And I want to run the query:
Expand|Select|Wrap|Line Numbers
  1. INSERT INTO "orvos" ("idorvos","nev") VALUES (DEFAULT,'TESZT')
...and got the response
Expand|Select|Wrap|Line Numbers
  1. ERROR:  relation "idorvos" does not exist
  2.  
I cannot change the query because it comes from PHPCake

Please tell me what the problem might be.

Thanks
z
INSERT INTO "orvos" (idorvos,nev) VALUES (DEFAULT,'TESZT')
Jan 18 '08 #2

P: 27
INSERT INTO "orvos" (idorvos,nev) VALUES (DEFAULT,'TESZT')
Unfortunately that does not make a difference.
Jan 18 '08 #3

Expert 100+
P: 700
Unfortunately that does not make a difference.
Did you receive the same error?
Do you have a sequence called idorvos?
Jan 18 '08 #4

P: 27
Did you receive the same error?
Do you have a sequence called idorvos?
Thank you a lot. That was the problem, the problem was with the sequence, which didn't exists...

Best Luck
z
Jan 18 '08 #5

Post your reply

Sign in to post your reply or Sign up for a free account.