0

I saw a similar question in Stackoverflow, but it was not answered. Please let me know if this question is already answered elsewhere. Sorry for the noise. If not, here is my question.

I'm connected to Vertica from R through RJDBC. I have no problem in querying and getting results like select * <tablename>. But I tried to create a table using the command

dbSendQuery(vertica, "create table schema.tablename(
   ID      INTEGER,
   PRODUCT VARCHAR(100))
   ORDER BY ID
   UNSEGMENTED ALL NODES;")

I get this error

Error in .verify.JDBC.result(r, "Unable to retrieve JDBC result set for ", : Unable to retrieve JDBC result set for create table schema.tablename( ID INTEGER, PRODUCT VARCHAR(100) ORDER BY ID UNSEGMENTED ALL NODES; ([Vertica]JDBC A ResultSet was expected but not generated from query "create table schema.tablename(

I wonder, how I should create a table in vertica through R using RJDBC.

Thanks.

cobarzan
  • 664
  • 3
  • 11
  • 23
Hash
  • 11
  • 2
  • You may want to try `dbSendUpdate()` instead, no? – mustaccio Dec 10 '15 at 16:43
  • That works. Thanks a lot. – Hash Dec 10 '15 at 22:14
  • Hi, now I'm trying to connect Oracle from R. I followed the steps from [link](http://stackoverflow.com/questions/11407116/connecting-oracle-from-r) but still I get `Error in .jfindClass(as.character(driverClass)[1]) : class not found.` – Hash Mar 10 '16 at 22:01
  • If you have a different question, post it as a different question. – mustaccio Mar 10 '16 at 22:21
  • Hi, now I'm trying to connect Oracle from R. I followed the steps from link. My driver connection oDriver = JDBC(driverClass="oracle.jdbc.OracleDriver", classPath="/path/ojdbc7.jar") but still I get Error in .jfindClass(as.character(driverClass)[1]) : class not found. I have ORACLE_HOME, LD_LIBRARY_PATH setup. I'm not sure what else I'm missing – Hash Mar 10 '16 at 22:21

0 Answers0