[R-sig-DB] ODBC driver in ubuntu

Luis Ridao |ur|d@o @end|ng |rom gm@||@com
Wed Oct 30 14:30:52 CET 2013


You mean:

> channel <- odbcConnect(dsn='BASTA', uid='*****', pwd='********')

Warning messages:
1: In odbcDriverConnect("DSN=BASTA;UID=luisr;PWD=juanayzakarias") :
  [RODBC] ERROR: state IM002, code 0, message [unixODBC][Driver
Manager]Data source name not found, and no default driver specified
2: In odbcDriverConnect("DSN=BASTA;UID=luisr;PWD=juanayzakarias") :
  ODBC connection failed

or in the odbc.ini file:
/etc$ sudo gedit odbc.ini

[oracle_driver]
driver        = OracleODBC-11g
description        = Oracle_ODBC_driver
server        = BASTA
port        = 1521
sid        = 192.168.20.10
user        = ********
password        = *********
logging        = No
logfile        =
enable_user_catalog        = yes
enable_synonyms        = yes
metadata_dont_change_case        = no
metadata_dont_do_schema        = no
metadata_id        = no
limit_long        = 0

It keeps on failing

Best,
Luis


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
Luis Ridao Cruz
Faroe Marine Research Institute
N�at�n 1, P.O. Box 3051
FO-110 T�rshavn
Faroe Islands
Tel   : (+298) 353900
Fax: : (+298) 353901
e-mail: luisr using hav.fo
           luridao using gmail.com
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-



On Wed, Oct 30, 2013 at 1:22 PM, Prof Brian Ripley <ripley using stats.ox.ac.uk>wrote:

> On 30/10/2013 13:18, Luis Ridao wrote:
>
>> R-sig-DB help,
>>
>>
>> I'm trying to connect to an oracle database through R.
>> I have installed the oracle client and it seems that the driver is also
>> installed.
>> However the connection fails:
>>
>
> You have not specified a DSN called BASTA nor basta.
>
>>
>>  library(RODBC)
>>>
>> # WITH DATABASE NAME
>>
>>> channel <- odbcConnect('192.168.20.10', uid='my_uid', pwd='my_pwd')
>>>
>> Warning messages:
>> 1: In odbcDriverConnect("DSN=192.**168.20.10;UID=luisr;PWD=**juanayzakarias")
>> :
>>    [RODBC] ERROR: state IM002, code 0, message [unixODBC][Driver
>> Manager]Data source name not found, and no default driver specified
>> 2: In odbcDriverConnect("DSN=192.**168.20.10;UID=luisr;PWD=**juanayzakarias")
>> :
>>    ODBC connection failed
>> # WITH DATABASE IP
>>
>>> channel <- odbcConnect('BASTA', uid='my_uid', pwd='my_pwd')
>>>
>> Warning messages:
>> 1: In odbcDriverConnect("DSN=basta;**UID=luisr;PWD=juanayzakarias") :
>>    [RODBC] ERROR: state IM002, code 0, message [unixODBC][Driver
>> Manager]Data source name not found, and no default driver specified
>> 2: In odbcDriverConnect("DSN=basta;**UID=luisr;PWD=juanayzakarias") :
>>    ODBC connection failed
>>
>> My odbc.ini file looks like:
>>
>> $ sudo gedit odbc.ini
>> [oracle_driver]
>> driver        = OracleODBC-11g
>> description        = Oracle_ODBC_driver
>> server        = basta
>> port        = 1521
>> sid        = 192.168.20.10
>> user        = my_uid
>> password        = my_pwd
>> logging        = No
>> logfile        =
>> enable_user_catalog        = yes
>> enable_synonyms        = yes
>> metadata_dont_change_case        = no
>> metadata_dont_do_schema        = no
>> metadata_id        = no
>> limit_long        = 0
>>
>> $ sudo gedit odbcinst.ini
>> [OracleODBC-11g]
>> Description = Oracle ODBC driver for Oracle 11g
>> Driver = /u01/app/oracle/product/11.1.**0/client_2/lib/libsqora.so.11.**1
>> FileUsage = 1
>> Driver Logging = 7
>>
>>
>> can anyone help?
>>
>> best,
>> Luis
>>
>>         [[alternative HTML version deleted]]
>>
>> ______________________________**_________________
>> R-sig-DB mailing list -- R Special Interest Group
>> R-sig-DB using r-project.org
>> https://stat.ethz.ch/mailman/**listinfo/r-sig-db<https://stat.ethz.ch/mailman/listinfo/r-sig-db>
>>
>>
>
> --
> Brian D. Ripley,                  ripley using stats.ox.ac.uk
> Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~**ripley/<http://www.stats.ox.ac.uk/~ripley/>
> University of Oxford,             Tel:  +44 1865 272861 (self)
> 1 South Parks Road,                     +44 1865 272866 (PA)
> Oxford OX1 3TG, UK                Fax:  +44 1865 272595
>
> ______________________________**_________________
> R-sig-DB mailing list -- R Special Interest Group
> R-sig-DB using r-project.org
> https://stat.ethz.ch/mailman/**listinfo/r-sig-db<https://stat.ethz.ch/mailman/listinfo/r-sig-db>
>

	[[alternative HTML version deleted]]




More information about the R-sig-DB mailing list