This question already has an answer here:
I am trying to add a geometry column to an existing table in PostgreSQL inside a plpgsql function using
EXECUTE format('ALTER table %I add column geom geometry(Point, 102003)', target_table);
There is PostGIS extension installed in the database which I am running. Only thing is my table are not in public schema.