Skip to content

postgis_insert with schema? #9

@aazaff

Description

@aazaff

I'm having trouble using postgis_insert( ) when I try to specify a schema

# Create the table
dbSendQuery(Connection,"CREATE TABLE mytable (id numeric, geom geometry);")
# Write the geometry to postgres		
postgis_insert(Connection, Table, "mytable", geom_name = "geom")

Works fine.

However, it does not work if I put it in a schema.

# Create the table
dbSendQuery(Connection,"CREATE TABLE myschema.mytable (id numeric, geom geometry);")
# Write the geometry to postgres		
postgis_insert(Obis, ContinentalBlocks, "myschema.mytable", geom_name = "geom")

Error in postgresqlExecStatement(conn, statement, ...) : 
  RS-DBI driver: (could not Retrieve the result : ERROR:  relation "myschema.mytable" does not exist
LINE 1: INSERT INTO "myschema.mytable...

Is there a different way to specify schema?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions