Skip to main content
Question

ODBC client driver - COPY LOCAL disabled? (ERROR 5873)

  • August 21, 2023
  • 4 replies
  • 9 views

tzahpahima123

I have a system running with multiple versions of the ODBC driver for windows.
The version I have deployed on most hosts is the 9.2 ODBC driver.
I need to use the COPY LOCAL command, but for some reason it seems like the clients do not support it (or maybe the problem has to do with my configuration on the client/server).
The error is as following:
ERROR [HY000] [Vertica][VerticaDSII] (210) Data streaming error: ERROR 5783: Client error: Copy local has been disabled on this connection (in function () at Bulkload.cpp:288)

How do I resolve this and allow for COPY LOCAL to be performed? Is it some connection property I am not aware of? Something in the .INI file? Or maybe some configuration on the server.

4 replies

SruthiA
Forum|alt.badge.img+1
  • Participating Frequently
  • August 21, 2023

Please check if you have set DisableCopyLocal to 1 in your properties. if so, error is expected. please unset it and then try copy local


tzahpahima123
  • Author
  • New Participant
  • August 21, 2023

@SruthiA said:
Please check if you have set DisableCopyLocal to 1 in your properties. if so, error is expected. please unset it and then try copy local

Thank you, actually I had a "vertica.ini" file previously deployed in the same directory with "DisableCopyLocal=1".
It seems as if the connection string did not help, and the INI file overrided it.
Do you know if there is any solution other than changing the "vertica.ini"?
Either way you answered my question, thank you!


SruthiA
Forum|alt.badge.img+1
  • Participating Frequently
  • August 21, 2023

Sergey_Cherepan_1
Forum|alt.badge.img+2

You can make ODBC driver to ignore odbc.ini by using SQLDriverConnect and passing all connect info in connection string:

isql -3 -k 'driver=/opt/vertica/lib64/libverticaodbc.so;database=;servername=vdb.vertica.com;uid=dbadmin;pwd=supersecret;label=Vertica example'
+---------------------------------------+
| Connected!                            |
|                                       |
| sql-statement                         |
| help [tablename]                      |
| echo [string]                         |
| quit                                  |
|                                       |
+---------------------------------------+

isql is part of unixODBC rpm.
As you can see, DNS configuration is not required, you can use ODBC in mode similar to JDBC, with passing connection URL.

While you do not need odbc.ini or can make ODBC driver to ignore it, odbcinst.ini is always in force.