Skip to content
Prev 1038 / 1559 Next

How to write to database schema other than public using RPostgreSQL

Hi,
You don't show what table exists in reality.
The code for dbExistsTable checks only for current schema and  
tablename is just the
table name whethere or not tablename includes any number of periods.

What do you get with the following and do you compare the results  
with dbExistsTable?
dbGetQuery(con, 'select * from "rtest" LIMIT 0' )
dbGetQuery(con, 'select * from "public.rtest" LIMIT 0' )
dbGetQuery(con, 'select * from "amber.rtest" LIMIT 0' )
dbGetQuery(con, 'select * from public.rtest LIMIT 0' )
dbGetQuery(con, 'select * from amber.rtest LIMIT 0' )