Showing posts with label table. Show all posts
Showing posts with label table. Show all posts

Jan 4, 2011

org.postgresql.util.PSQLException: ERROR: syntax error at or near

This happen when you have a name which is a reserved name or already exists by a table for example.

Lets say your are trying to add a new table and the error was:
org.postgresql.util.PSQLException: ERROR: syntax error at or near "User"

You got this error since the postgresql in the current schema has already a User table and this name is reserved.
Change your table (if in your case like this example, it's a table issue) name to a different.

Hoped it helps.

Dor

Nov 24, 2010

insert ampersand in oracle table

Hi,
This solution will work everywhere, no matter if you are using TOAD,sql plus, pl sql developer.
let's say we want to insert this "hello&world" inside a table that includes key's and values.
And our key, let's say is "title"
For example :
insert into table_name (keys,values) values ('title','hello'||chr(38)||'world');
That's the whole story.
Hoped i helped,
Dor