Skip to main content

Can vertica-jdbc support "copy" keyword to load data from csv files?

  • October 20, 2016
  • 1 reply
  • 12 views

Wayne66

My vertical version is "Vertica Analytic Database v7.2.3-0". My requirement is to load csv files into table by JDBC method. I tried to use "vsql' to load data. It was working.

But use jdbc to execute same sql statement. It raised exception "java.sql.SQLSyntaxErrorException: [Vertica][VJDBC](4368) ERROR: Permission denied for storage location". 

So I want to know if "vertical-jdbc" doesn't support "copy" keyword? 

 

The following was example code:

 

Connection con = DriverManager.getConnection(m_VerticaDBURL, m_VerticaDBUserName, m_VerticaDBPassword);
Statement st = con.createStatement();
st.execute(strSql)

1 reply

HPELC2A
Forum|alt.badge.img
  • Participating Frequently
  • October 23, 2016

Can u share the output of the final string of 'strSql'