I got NET: Invalid SID error

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
odacuil
Posts: 8
Joined: Tue 08 Aug 2006 07:33

I got NET: Invalid SID error

Post by odacuil » Tue 08 Aug 2006 08:05

In most cases, ODAC works well.
But recently, I got NET: Invalid SID error.
The following is the server information:

SQL> select * from v$version;


BANNER

----------------------------------------------------------------

Oracle9i Enterprise Edition Release 9.2.0.1.0 -Production

PL/SQL Release 9.2.0.1.0 -Production

CORE 9.2.0.1.0Production


TNS for Compaq Tru64 UNIX: Version 9.2.0.1.0 -Production

NLSRTL Version 9.2.0.1.0 - Production

PARAMETER VALUE

----------------------------------------------------------------
----------------------------------------------------------------

NLS_LANGUAGE AMERICAN

NLS_TERRITORY AMERICA

NLS_CURRENCY $

NLS_ISO_CURRENCY AMERICA

NLS_NUMERIC_CHARACTERS .,

NLS_CALENDAR GREGORIAN

NLS_DATE_FORMAT DD-MON-RR

NLS_DATE_LANGUAGE AMERICAN

NLS_CHARACTERSET WE8ISO8859P1

NLS_SORT BINARY

NLS_TIME_FORMAT HH.MI.SSXFF AM

NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM

NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR

NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR

NLS_DUAL_CURRENCY $

NLS_NCHAR_CHARACTERSET AL16UTF16

NLS_COMP BINARY

NLS_LENGTH_SEMANTICS BYTE

NLS_NCHAR_CONV_EXCP FALSE
19 rows selected

The client is WindowXP with Simplified Chinese Version.

When I use Oracle Client driver, and I set orasession.net to false,
the servername is the tnsname, ODAC can connect to the server well and work well .

But when I set orasession.options.net to true, the SID to the SID, host to the IP, port to 1521,
that is IP:1521:SID
I got NET: Invalid SID error.

Previously, ODAC do work well. But in this case, I can not understand why? Maybe the NLS_LANG?
Most ODAC with 4.X versions produce the same result.

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Fri 11 Aug 2006 08:43

Check if IP address, port and SID you specify are correct. In some cases SID can differ from service name.

odacuil
Posts: 8
Joined: Tue 08 Aug 2006 07:33

Post by odacuil » Fri 11 Aug 2006 12:20

But the IP,port and SID are actually the same as those that I set in oracle client software. The oracle client software works well but ODAC shows "Invalid SID". I do know the local Service name is not SID. I am considering if ODAC can work well if the NLS_LANG of server and client are different .

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 14 Aug 2006 09:11

If you are using DNS name in Server property then try to use IP address instead. For example:
192.168.1.1:1521:ORA920

odacuil
Posts: 8
Joined: Tue 08 Aug 2006 07:33

Post by odacuil » Fri 18 Aug 2006 15:27

I do use the IP

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 21 Aug 2006 09:20

Please inform us about ODAC version you use (see Odac\About ODAC in Delphi menu).
Provide us a fragment from tnsnames.ora file that describes your database.
Please send to ODAC support address sample project that demonstrates the problem and include script to create server objects.
Check if the problem can be reproduced in ODAC demos.

odacuil
Posts: 8
Joined: Tue 08 Aug 2006 07:33

Post by odacuil » Fri 25 Aug 2006 12:51

The version of ODAC is 5.70.1.34
OPS =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.228.0.31)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = OPS)
)
)

the connectstring is 10.228.0.31:1521:ops
I can not connect to the server when option.net is true, while it works well if option.net is false and session.server is ops.

But I can not provide the scripts to generate the database.
Thanks

odacuil
Posts: 8
Joined: Tue 08 Aug 2006 07:33

Post by odacuil » Sun 27 Aug 2006 09:18

The problem is solved. I mistake the databasename for the SID.
Thanks

Post Reply