[unixODBC][Driver Manager]Invalid cursor state on HP -UX - odbc

I am using open source ODBC driver manager with our driver and i am getting this error
24000(0)[unixODBC][Driver Manager]Invalid cursor state
I tried to debug in my driver but no help there.
Please can you explain me is this error is coming from driver manager or from mine driver.

The error is coming from the driver manager. You will be calling ODBC functions out of sequence. Turn on driver manager tracing, in your odbcinst.ini add
[ODBC]
Trace = Yes
TraceFile = /tmp/sql.log
Then run your app and see what lead up to the error.

Related

Snowflake ODBC driver (64 bit) error while setting up DSN

I am trying to set up Data Source Name for Snowflake database connection using ‘ODBC Data Sources (64 bit)’. I have downloaded and installed Snowflake ODBC driver. I do see ‘SnowflakeDSII Driver’ in the ODBC driver list. When I try to setup Data Source Name, I am running into the following error …
[SIMBA][DSI] An error occurred while attempting to retrieve the error message for key 'DSN Error' and Component ID 102:
Invalid source component ID: 102
Appreciate your help in resolving this issue.
Thanks.
Venkat.
The issue is now resolved.
After specifying value for 'Data Source', it allowed me to create the DSN.
Thanks.
Venkat.

Simba Athena ODBC: unable to use SQLGetPrivateProfileString functions

This is very strange, I want to setup a connection from RStudio to my instance in AWS Athena.
I am using unixodbc as the driver manager, and succeded by testing the connection using isql -v 'Simba Athena'. However, when I test the connection in RStudio with...
con <- DBI::dbConnect(
odbc::odbc(),
"Simba Athena"
)
... it gives me the error Error: nanodbc/nanodbc.cpp:1021: 00000: [Simba][ODBC] (11560) Unable to locate SQLGetPrivateProfileString function.. Any clue about it, I am a bit stuck.
It is basically not finding the correct ODBC driver. Simba by default references the driver in its /Library/simba/athenaodbc/lib/simba.athenaodbc.ini setup file to libodbc.dylib but it should be libodbcinst.dylib. At least in MacOS.
This solved my problem.
I got the same error when I link with static library of "libodbc.a", however I can succeed to connect when I change to link with dynamic library of "libodbc.so"

Error when trying to connect to Teradata as source using Attunity

I am getting the following error when I try to connect to Teradata as source using attunity
"SYS-E-HTTPFAIL, Cannot connect to ODBC provider Fatal error has occurred."
I have restarted Attunity console and server
screenshot of the error
I confirmed that Teradata ODBC is installed and I can connect to Teradata
There are multiple reasons for these errors:
1- In my case I needed to update the environment variable and ensure to enter the correct path to Teradata ODBC driver
2- Other reasons for the error is ensure you are running a 64 bit ODBC driver matching Attunity 64 bit download

Install odbc drive for drill

I followed these steps to config the odbc drive for drill:
Configuring ODBC on Linux
After that I try to test the drill connection according Testing the ODBC Connection Instruction
/usr/bin/iodbctest
iODBC Demonstration program
This program shows an interactive SQL processor
Driver Manager: 03.52.0709.0909
Enter ODBC connect string (? shows list): DSN=Drill;ConnectionType=ZooKeeper;ZKQuorum=192.168.0.253:2181,192.168.0.254:2181;ZKClusterID=drillbits1
Driver: 1.2.0.1000 (MapR Drill ODBC Driver)
SQL>select columns[0] as 'Year',columns[1] as Revenues from 'hdfs.root'.'./user/hdfs/R/DisneyFinancialTest.csv'
1: ERROR [HY000] [MapR][Drill] (1070) Drill fails to execute the query with error [30017]Communication error. End of file
It works well with the connection to sql, but it shows that the drill fails to execute. What does the issue means? Can anyone help me trouble shot this problem?
quit; is interpreted as a SQL command, which is not valid for Drill. If you want to quit isql, then just use quit.
Finally I found out what was the issue, the problem was that my odbc driver version and my drill version is not match. I uninstalled the drill odbc driver 1.2 and installed version 0.8, it works well.
I solved the problem by referencing this link.

Connecting to MS Access Database from R (x64)

I am trying to access my Access database using R. I have tried the below options but I am not able to connect to the database. I am using 64 bit R and 64 bit Access. I am using windows 7 also.. :(
library(RODBC)
db <- "E:/testdb.accdb"
myconn <-odbcDriverConnect("Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=E:/test.accdb")
con2 <- odbcConnect(db)
channel <- odbcConnectAccess("E:/testdb")
I always get the error. Please help me.
1: In odbcDriverConnect("DSN=E:/testdb.accdb") :
[RODBC] ERROR: state IM002, code 0, message [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
2: In odbcDriverConnect("DSN=E:/testdb.accdb") : ODBC connection failed
I think the problem is as error message suggests - you don't have x64 Microsoft Access driver installed. Check it in Control panel - ODBC Data Sources (x64) on the Drivers tab. If it's not there, try to install Microsoft Access Database Engine 2010 Redistributable.

Resources