Thread: ​ERROR: syntax error at or near "collation"

​ERROR: syntax error at or near "collation"

From
dbatoCloud Solution
Date:

Hi All,

I am getting the below error while executing sql file in postgresql ? Can somebody suggest plz?


SETpsql:comsod_db_structure.sql:48: ERROR:  syntax error at or near "collation"

LINE 37:  collation varchar(100)


Thanks

Ashok

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Ashokkumar Mani

 +91 81975 99922 

W: https://dbatocloudsolution.blogspot.in/ | E: dbatocloud17@gmail.com



Re: ​ERROR: syntax error at or near "collation"

From
"David G. Johnston"
Date:
On Thursday, January 13, 2022, dbatoCloud Solution <dbatocloud17@gmail.com> wrote:

Hi All,

I am getting the below error while executing sql file in postgresql ? Can somebody suggest plz?


SETpsql:comsod_db_structure.sql:48: ERROR:  syntax error at or near "collation"

LINE 37:  collation varchar(100)


Don’t use reserved words as column names.

David J.
 

Re: ​ERROR: syntax error at or near "collation"

From
"David G. Johnston"
Date:


On Thursday, January 13, 2022, David G. Johnston <david.g.johnston@gmail.com> wrote:
On Thursday, January 13, 2022, dbatoCloud Solution <dbatocloud17@gmail.com> wrote:

Hi All,

I am getting the below error while executing sql file in postgresql ? Can somebody suggest plz?


SETpsql:comsod_db_structure.sql:48: ERROR:  syntax error at or near "collation"

LINE 37:  collation varchar(100)


Don’t use reserved words as column names.


Precisely…the word being complained about, “collation”, is reserved [1].  Rename the column or double-quote it.


David J.