I'm trying to update a column public_geometry in a table by creating a point from longitude and latitude cols from the same table. The database is PostgreSQL with Pgadmin as program to handle the databasse:
UPDATE sirene_test.etablisssement_actif
SET geom=ST_GeometryFromText('POINT('|| latitude ||' '|| longitude ||')', 4326);
I got this Error :
ERREUR: parse error - invalid geometry
HINT: "POINT( )" <-- parse error at position 9 within geometry
********** Erreur **********
ERREUR: parse error - invalid geometry
État SQL :XX000
Astuce : "POINT( )" <-- parse error at position 9 within geometry
select 'POINT('|| latitude ||' '|| longitude ||')' from sirene_test.etablisssement_actif limit 3
?where latitude is not null and longitude is not null
.ST_SetSRID(ST_MakePoint(longitude,latitude),4326)