Ora-24508 error when selecting a date field and rowid when using Unicode = true

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Ora-24508 error when selecting a date field and rowid when using Unicode = true

Post by DarrenColes » Thu 09 Aug 2007 14:08

This code:
OracleConnection oc = new OracleConnection();
oc.ConnectionString = "pooling = false";
oc.Unicode = true;
oc.AutoCommit = true;
oc.Server = "development";
oc.UserId = "user";
oc.Password = "pass";
oc.Open();

OracleCommand o2 = oc.CreateCommand();
o2.CommandType = CommandType.Text;
o2.ParameterCheck = true;

o2.CommandText = "drop table abc";
try
{ o2.ExecuteNonQuery(); }
catch
{ }

o2.CommandText = "create table abc (a varchar2(4000), b date)";
o2.ExecuteNonQuery();

o2.CommandText = "insert into abc (a,b) values ('aasaaadsfsdfsdfsdfsd',sysdate)";
o2.ExecuteNonQuery();

o2.CommandText = "select b,rowid from abc";
OracleDataReader or = o2.ExecuteReader();
if (or.Read())
{
or.GetString(0);
}
or.Close();
or.Dispose();
or = null;

when run on our environment produces a very vague "ora-24508 : Message 24508 not found" error. According to the internet this error is "Buffer not aligned correctly".

This only happens when Unicode = true.

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Thu 09 Aug 2007 14:46

What version of OraDirect .NET do you use? I can't reproduce this problem with the latest beta.
Have you tried another Oracle data provider?

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Thu 09 Aug 2007 14:51

I'm using 3.55.23 and no I haven't tried using another provider. I will try that now. The old version of the software that was written in Delphi using the Core Lab ODAC component works fine with the query however.

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Thu 09 Aug 2007 15:02

this code which uses the System.Data.OracleClient classes works as expected.

System.Data.OracleClient.OracleConnection oc = new System.Data.OracleClient.OracleConnection();
oc.ConnectionString = "pooling = false; data source = development; unicode = true; User Id=user;Password=pass";
//oc.Unicode = true;
//oc.AutoCommit = true;
//oc.Server = "development";
//oc.UserId = "top_level";
//oc.Password = "top_level";
oc.Open();

System.Data.OracleClient.OracleCommand o2 = oc.CreateCommand();
o2.CommandType = CommandType.Text;
//o2.ParameterCheck = true;

o2.CommandText = "drop table abc";
try
{ o2.ExecuteNonQuery(); }
catch
{ }

o2.CommandText = "create table abc (a varchar2(4000), b date)";
o2.ExecuteNonQuery();

o2.CommandText = "insert into abc (a,b) values ('aasaaadsfsdfsdfsdfsd',sysdate)";
o2.ExecuteNonQuery();

o2.CommandText = "select b,rowid from abc";
System.Data.OracleClient.OracleDataReader or = o2.ExecuteReader();
if (or.Read())
{
or.GetDateTime(0);
or.GetString(1);
}
or.Close();
or.Dispose();
or = null;

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Thu 09 Aug 2007 15:43

Just tried your code with 3.55.23. Still no exception.
What are the versions of your Oracle server and client?

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Thu 09 Aug 2007 16:08

Oracle Server version 9.2.0.8 and Oracle Client version 9.2.0.6

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Fri 10 Aug 2007 08:49

I downloaded a trial version of OraDirect 4.00 and this appears to be fixed in that version

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Fri 10 Aug 2007 09:06

Very well.

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Fri 10 Aug 2007 09:08

However the previous bug we reported with parameters getting truncated does not appear to be fixed in version 4.00, only version 4.20.

If we buy an upgrade from version 3 to version 4, will we get a registered version of 4.20?

Also I would need to discuss with the rest of our business to decide if we were comfortable to go with a beta version of OraDirect in our product.

Is there an ETA for the final version of 4.20?

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Fri 10 Aug 2007 10:12

If we buy an upgrade from version 3 to version 4, will we get a registered version of 4.20?
Yes, of course.
Is there an ETA for the final version of 4.20?
Hopefully, we will release it next week.

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Mon 13 Aug 2007 09:49

Could you be more specific as to when this week? I need to make a decision whether or not to disable the unicode support in our app, or wait for this version to be released and unfortunately we didnt spot this issue until the app was deployed in our live environment.

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Wed 15 Aug 2007 07:24

Hopefully, we will upload new build tomorrow.

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Thu 16 Aug 2007 16:05

Can you please provide me with an update for when you expect version 4.20 to be released?

We really need a version of the component with both of our issues fixed as soon as possible.

Alexey
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Post by Alexey » Fri 17 Aug 2007 07:10

We released new version of 4.00 yesterday.
Could you please specify, what bugs are not fixed in 4.00?

DarrenColes
Posts: 47
Joined: Mon 28 Aug 2006 11:07

Post by DarrenColes » Fri 17 Aug 2007 08:33

the bug we mentioned here

http://www.crlab.com/forums/viewtopic.php?t=9958

which is fixed in 3.55.23 according to the version history which says

Bug with long string parameters fixed

this is not mentioned in the version 4 history anywhere and does not appear to be fixed.

This is very serious for us now, as we paid to upgrade to version 4 expecting a release this week that fixes both issues. I really hope you can provide an update to version 4 that fixes both issues ASAP.

Post Reply