sqlpostgresqlquoted-identifier

Updating a PostgreSQL column that contains dot (.) in its name


I should update the value of a row, but the column name has the dot.

I tried name.name but nothing, even though it seems to work on MySQL.

How can I do with postgresql? I swear that before creating this thread I searched all over.

Thanks

UPDATE: Thanks for the quick answers, I tried to use "" but this is the result

ERROR:  column "name.name" of relation "my_table" does not exist

My query:

update my_table set "name.name"='a081613e-2e28-4cae-9ff7-4eaa9c918352';

Solution

  • You can use "" around the column name