SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

Connect from SAS to AWS Athena (JDBC)

Accepted Solution Solved
Reply
New Contributor
Posts: 4
Accepted Solution

Connect from SAS to AWS Athena (JDBC)

[ Edited ]

I am trying to establish a connection between SAS & AWS Athena. I am working on RHEL 6.7, java version is 1.8.0_71.

I have SAS/ACCESS to ODBC installed.

 

Could someone advise how to configure that please?

 

So far, after some reading on "Accessing Amazon Athena with JDBC" , I have tried a 'maybe it will work' naive approach with trying to set a DSN in odbc.ini files (outside of SAS): I have downloaded Athena JDBC jar file and tried configuring connection in a similar way I did it for EMR.

As expected, it didn't work and iODBC throws the following:

iODBC Demonstration program
This program shows an interactive SQL processor
Driver Manager: 03.52.0709.0909

Enter ODBC connect string (? shows list): DSN=ATHENA
1: SQLDriverConnect = [iODBC][Driver Manager]/opt/amazon/hiveodbc/lib/64/AthenaJDBC41-1.1.0.jar: invalid ELF header (0) SQLSTATE=00000
2: SQLDriverConnect = [iODBC][Driver Manager]Specified driver could not be loaded (0) SQLSTATE=IM003

As someone commented on SO, I should try using some ODBC-JDBC bridge but not sure how to approach this topic - all I have found so far covers accessing ODBC source, but that is not the case here (there is only jdbc driver for Athena).

 

Has anyone tried making such connection before? Is it even possible?


Accepted Solutions
Solution
‎03-16-2018 03:25 PM
New User
Posts: 1

Re: Connect from SAS to AWS Athena (JDBC)

Posted in reply to kibicrealu1

All Replies
SAS Employee
Posts: 264

Re: Connect from SAS to AWS Athena (JDBC)

[ Edited ]
Posted in reply to kibicrealu1

Hi @kibicrealu1

 

There are ODBC to JDBC bridges. DataDirect provides one called SequeLink. You can find out about it here: https://www.progress.com/connectors/sequelink

 

PROC GROOVY can do this... 
LilyAnne Zhang wrote an excellent SAS Global Forum paper on this topic.
Accessing DBMS with the Groovy Procedure and a JDBC Connection.

 

Hope this helps,
Jeff

New Contributor
Posts: 4

Re: Connect from SAS to AWS Athena (JDBC)

Many thanks for a quick reply@JBailey, will read it through and let know of the progress.

 

Cheers!

New Contributor
Posts: 4

Re: Connect from SAS to AWS Athena (JDBC)

Posted in reply to kibicrealu1

 

I have installed ODBC-JDBC bridge from Easysoft, configured connection and tested using isql with -v -e options.

However, in SAS I am getting CLI prepare error:Untitled.png

 

Is there any way to cope with that in SAS?

Tried using dbidirectexec option (wanted to force SQLExecDirect instead of SQLPrepare & SQL Execute ) but no luck with that too.

I have opened a Support Track with SAS but no luck so far - hoping that someone may have experienced something similar in the past

 

Thanks

 

Solution
‎03-16-2018 03:25 PM
New User
Posts: 1

Re: Connect from SAS to AWS Athena (JDBC)

Posted in reply to kibicrealu1
New Contributor
Posts: 2

Re: Connect from SAS to AWS Athena (JDBC)

Posted in reply to kibicrealu1

Hi 

We are trying to connect SAS to AWS Athena by using ODBC/JDBC driver.

RHEL 6.7 , java version "1.7.0_79"

 

erarlier you faced an issue on this configuration .. is it resolved ?

please share the steps you followed.

Thanks

SAS Employee
Posts: 264

Re: Connect from SAS to AWS Athena (JDBC)

Posted in reply to srinivask

Hi @srinivask

 

This is a solved issue. It may be best to open up a new message containing the specifics of the issue you are having.

 

Feel free to mention my name in the new message because I would like to help with it.

 

Best wishes,

Jeff

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 6 replies
  • 871 views
  • 2 likes
  • 4 in conversation