<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Libname odbc stament error in linux in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877759#M346752</link>
    <description>&lt;P&gt;I've never had luck with using the NOPROMPT method from linux, but the second libname statement looks good to me:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;LIBNAME SAMPLE2 ODBC DATAsrc=NAMESRC_S SCHEMA=dbo USER=usr_XX PASSWORD="{SAS222}828A4PP5CB131A25BC" ;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;You get:&lt;/P&gt;
&lt;PRE&gt;ERROR: The SAS/ACCESS Interface to ODBC cannot be loaded. The SASODB code appendage could not be loaded.&lt;/PRE&gt;
&lt;P&gt;from that as well?&amp;nbsp; When you run the batch job, are your running it on the same linux SAS server which EG is connected to?&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 26 May 2023 18:49:57 GMT</pubDate>
    <dc:creator>Quentin</dc:creator>
    <dc:date>2023-05-26T18:49:57Z</dc:date>
    <item>
      <title>Libname odbc stament error in linux</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877755#M346750</link>
      <description>&lt;P&gt;Hi experts!&lt;/P&gt;
&lt;P&gt;I'm executing a sas program from linux command line, example:&lt;/P&gt;
&lt;P&gt;/sas94/sashome/SASFoundation/9.4/sasexe/sas program.sas&lt;/P&gt;
&lt;P&gt;I have to assign a libname to connect a sql server database to obtain the data, but I have this problem&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ERROR: Could not load /sas94/sashome/SASFoundation/9.4/sasexe/sasodb (32 images loaded)&lt;BR /&gt;ERROR: /sas94/sapiq160/IQ-16_0/lib64/libodbc.so: version `VERS_3.52' not found (required by&lt;BR /&gt;/sas94/sashome/SASFoundation/9.4/sasexe/sasodb)&lt;BR /&gt;1 LIBNAME SAMPLE2 ODBC NOPROMPT="Driver=/opt/microsoft/msodbcsql17/lib64/libmsodbcsql-17.6.so.1.1;SERVER=999.99.9.999,8888;&lt;BR /&gt;1 ! DATABASE=example1;UID=usr_XX;&lt;BR /&gt;2 PWD=ABCD" SCHEMA=dbo;&lt;BR /&gt;ERROR: The SAS/ACCESS Interface to ODBC cannot be loaded. The SASODB code appendage could not be loaded.&lt;BR /&gt;ERROR: Error in the LIBNAME statement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I also have tried this:&amp;nbsp;LIBNAME SAMPLE2 ODBC DATAsrc=NAMESRC_S SCHEMA=dbo USER=usr_XX PASSWORD="{SAS222}828A4PP5CB131A25BC" ;&lt;/P&gt;
&lt;P&gt;and I obtain the same error.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;BUT, when I do it from SAS enterprice Guide, both libname staments work fine!&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;any idea?&lt;/P&gt;</description>
      <pubDate>Fri, 26 May 2023 18:31:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877755#M346750</guid>
      <dc:creator>Jose7</dc:creator>
      <dc:date>2023-05-26T18:31:50Z</dc:date>
    </item>
    <item>
      <title>Re: Libname odbc stament error in linux</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877759#M346752</link>
      <description>&lt;P&gt;I've never had luck with using the NOPROMPT method from linux, but the second libname statement looks good to me:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;LIBNAME SAMPLE2 ODBC DATAsrc=NAMESRC_S SCHEMA=dbo USER=usr_XX PASSWORD="{SAS222}828A4PP5CB131A25BC" ;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;You get:&lt;/P&gt;
&lt;PRE&gt;ERROR: The SAS/ACCESS Interface to ODBC cannot be loaded. The SASODB code appendage could not be loaded.&lt;/PRE&gt;
&lt;P&gt;from that as well?&amp;nbsp; When you run the batch job, are your running it on the same linux SAS server which EG is connected to?&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 May 2023 18:49:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877759#M346752</guid>
      <dc:creator>Quentin</dc:creator>
      <dc:date>2023-05-26T18:49:57Z</dc:date>
    </item>
    <item>
      <title>Re: Libname odbc stament error in linux</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877762#M346755</link>
      <description>Yes, I Obtain both errors (ODBC y SASODB), and it´s the same linux SAS server which EG is connected to&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 26 May 2023 19:01:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877762#M346755</guid>
      <dc:creator>Jose7</dc:creator>
      <dc:date>2023-05-26T19:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: Libname odbc stament error in linux</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877769#M346758</link>
      <description>&lt;P&gt;I guess it's possible that EG is using a different config file when it launches SAS.&amp;nbsp; The config file points to the ODBC connection info etc.&amp;nbsp; You might be able to work with your SAS admin to figure out what config file (and possibly other option) EG is using.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The other possible path would be to use another metadata-aware SAS client to batch submit the program.&amp;nbsp; My understanding is SAS Management Console can batch submit a program.&amp;nbsp; I've also used DI studio to define a simple job with a single %include statement.&amp;nbsp; Then if I deploy that job for scheduling, DI studio writes a .sas file that can be batch submitted from a shell script.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;On my linux server, the shell script (I think provided by sas is called sasbatch.sh).&amp;nbsp; So if I run:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;/opt/sas/sasconfig/.../BatchServer/sasbatch.sh 
  -sysin /quentin/myprogram.sas
  -batch
  -noterminal&lt;/PRE&gt;
&lt;P&gt;it will batch submit myprogram.sas.&amp;nbsp; And I think the shell script loads the config files that are used by EG (or I guess by the batch server), and it does the metadata login etc.&amp;nbsp; So all the stuff that EG automatically enables works.&lt;/P&gt;</description>
      <pubDate>Fri, 26 May 2023 19:42:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877769#M346758</guid>
      <dc:creator>Quentin</dc:creator>
      <dc:date>2023-05-26T19:42:11Z</dc:date>
    </item>
    <item>
      <title>Re: Libname odbc stament error in linux</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877827#M346794</link>
      <description>&lt;P&gt;As&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/19879"&gt;@Quentin&lt;/a&gt;&amp;nbsp;proposes: Use sasbatch.sh for your SAS batch jobs. This .sh gets built as part of a SAS installation and calls the .cfg and autoexec files that have been configure for your environment.&lt;/P&gt;</description>
      <pubDate>Sat, 27 May 2023 06:19:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Libname-odbc-stament-error-in-linux/m-p/877827#M346794</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2023-05-27T06:19:01Z</dc:date>
    </item>
  </channel>
</rss>

