当使用 isql 时,我得到这个:[IM002][unixODBC][Driver Manager]Data source name not found, and no default driver specified

when use isql,i got this: [IM002][unixODBC][Driver Manager]Data source name not found, and no default driver specified

当我键入流命令时:isql dsnOracle -v
我得到了:

  [IM002][unixODBC][Driver Manager]Data source name not found, and no default driver specified
    [ISQL]ERROR: Could not SQLConnect

我的配置文件:

        [root@localhost lib]# cat /etc/odbc.ini 
        [dsnOracle]
        Description = data source to oracle
        Driver = Oracle
        Servername = PARA_ORACLE
        port = 1521
        [root@localhost lib]# cat /etc/odbcinst.ini 
        [Oracle]
        Description = ODBC for Oracle 
        Driver  = /usr/lib/libsqora.so.11.1
        [root@localhost lib]# cat $TNS_ADMIN/tnsnames.ora 
        PARA_ORACLE =    
        (DESCRIPTION =     
            (ADDRESS_LIST =   (ADDRESS = (PROTOCOL = TCP)(HOST = 172.100.2.13)(PORT = 1521))         )    
             (CONNECT_DATA =               
             (SERVER = DEDICATED)      
             (SERVICE_NAME = orcl)        
            )  
        )
[root@localhost lib]# rpm -qa |grep oracle
oracle-instantclient11.2-odbc-11.2.0.1.0-1.x86_64
oracle-instantclient11.2-basic-11.2.0.1.0-1.x86_64
[root@localhost lib]# rpm -qa |grep ODBC
unixODBC-2.2.14-12.el6_3.x86_64

我已经尝试了很长时间,但我总是得到:找不到数据源名称。 (它与 x86 或 x64 有任何关系吗?)。 任何建议对我来说都很好。

最后我像这样更改了我的 /etc/odbc.ini 并且它起作用了。

[dsnOracle]
Application Attributes=T
Attributes=W
BatchAutocommitMode=IfAllSuccessful
BindAsFLOAT=F
CloseCursor=F
DisableDPM=F
DisableMTS=T
Driver=Oracle
DSN=OracleODBC-11g
EXECSchemaOpt=
EXECSyntax=T
Failover=T
FailoverDelay=10
FailoverRetryCount=10
FetchBufferSize=64000
ForceWCHAR=F
Lobs=T
Longs=T
MaxLargeData=0
MetadataIdDefault=F
QueryTimeout=T
ResultSets=T
SQLGetData extensions=F
Translation DLL=
Translation Option=0
DisableRULEHint=T
StatementCache=F
CacheBufferSize=20
UseOCIDescribeAny=F
UserID=userid
ServerName=PARA_ORACLE
Password=password