Page 1 of 1

Nhibernate 3.2 doesnt work related the Parameter names

Posted: Thu 04 Aug 2011 19:01
by flutos
Nhibernate 3.2 was just released and I was using it and found it doesnt work with the devart oracle driver anymore and I found it was related to the ParameterName field in the parameter. in a sqlstatement you will have paramters defined with a ":" , ie :P0 and if you create a new devart oracle parameter and pass in the name as ":P0" , then if you read it back it returns "p0" so it strips off the ":" . Unfortuantly this can cause some problem with nhibernate because it needs to look up parameters in the parameters collection by name and its looking for ":P0" because thats what it gave you when it created it but you are returning "P0" so it never finds the parameter and you end up with and error saying "not all paremters defined".

I wasnt sure who to blame for this but since the sqlserver pametername returns its prefix, ie "@p0" shouldnt you return the oracle prefix too ":p0" ? Also, have you noticed any problems with your driver and nhibernate 3.2?

let me know anyhow.

thanks

scott

Posted: Mon 08 Aug 2011 09:51
by Shalex
A similar issue was discussed at http://www.devart.com/forums/viewtopic.php?t=21508. Please try OracleUtils.OracleClientCompatible = true; in the OCI mode (via Oracle client). We are investigating the issue with OracleUtils.OracleClientCompatible = true; in the Direct mode.

Posted: Mon 08 Aug 2011 14:48
by flutos
adding OracleUtils.OracleClientCompatible = true;
generates this error:
ORA-01036 illegal variable name/number

so this doesnt seem to work either. Is there something I can do to get rid of this error?

thanks

scott

Posted: Tue 09 Aug 2011 16:44
by Shalex
We can reproduce the ORA-01036 error only in the Direct mode. We will notify you when this issue is fixed.

As a workaround, please use the OCI mode ("Direct=false;"). If you are getting this error in the OCI mode, try to localize the issue by monitoring the SQL statement that is send to server.
Download link: http://www.devart.com/dbmonitor/dbmon3.exe
Documentation: http://www.devart.com/dotconnect/oracle ... nitor.html

Posted: Tue 09 Aug 2011 18:16
by flutos
we actually need direct mode=true since we are running on mono so do you know if it would be fixed in the next month or 2?

thanks

scott

Posted: Wed 10 Aug 2011 07:36
by Shalex
We plan to fix the issue this month.

Posted: Wed 10 Aug 2011 11:39
by flutos
ok , that will work for us, we will just wait for the fix.

thanks

scott

Posted: Wed 31 Aug 2011 15:55
by JomKippur
How is the progress of fixing this bug? :)

Posted: Wed 31 Aug 2011 16:16
by flutos
I dont think its been done yet but technically there is still 1 day left in the month. ;)

Posted: Wed 31 Aug 2011 19:36
by JomKippur
;) You are right ... still one day left ;)

I'm working on CoreLab 4.75 and this controls have the same problem with Nh 3.2 - it's obvious. But I have one more problem (version 4.70 hadn't this problem) i call oracle pl-sql functions returning varchar and the results are always "some two strnge signs". Guys do you know this problem?
I have a question: do I need to buy another license to use newest dotConnect controls (released after 1 of september :) ) ?

Greeting
P.

Posted: Thu 01 Sep 2011 15:07
by Shalex
The bug with parameter names when OracleUtils.OracleClientCompatible=true in Direct mode is fixed. We will post here when the next build of dotConnect for Oracle is available for download. We plan to release it next week.
JomKippur wrote:I'm working on CoreLab 4.75 and this controls have the same problem with Nh 3.2 - it's obvious. But I have one more problem (version 4.70 hadn't this problem) i call oracle pl-sql functions returning varchar and the results are always "some two strnge signs". Guys do you know this problem?
Please try the latest (6.30.202) version of dotConnect for Oracle (trial version). If the problem persists with this version as well, please send us a small test project with the corresponding DDL/DML script to reproduce the issue in our environment.
JomKippur wrote:I have a question: do I need to buy another license to use newest dotConnect controls (released after 1 of september Smile ) ?
Seems like you have to renew your subcription (http://www.devart.com/dotconnect/oracle ... scriptions) to get access to the latest builds. Please contact our Sales department (sales at devart*com) to check the status of your subscription.

Posted: Wed 07 Sep 2011 12:03
by Shalex
New version of dotConnect for Oracle 6.50 is released!
It can be downloaded from http://www.devart.com/dotconnect/oracle/download.html (trial version) or from Registered Users' Area (for users with valid subscription only): http://secure.devart.com/ .
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=21942 .

Posted: Tue 20 Sep 2011 15:23
by JomKippur
After this patch I don't have a problem in Nh3.2 but I have this problem (ORA-01036 illegal variable name/number)
using simple Ado query with parameters:

insert into TestData(a, b) values(:a, :b)

when I set: OracleUtils.OracleClientCompatible = false;

simple Ado query is ok but Nh 3.2 is wrong ...

Why I have to use this setting: OracleUtils.OracleClientCompatible =true;?

thanks
JK

Posted: Wed 21 Sep 2011 09:37
by JomKippur
To sum up I want to use Nh 3.2 without this trick:

OracleUtils.OracleClientCompatible = true;

because OracleUtils.OracleClientCompatible = true; cause my Ado Daos not working.

I renewed my subcription in order to get working version for Nh 3.2.
But it doesn' work :(.

...

greetings
JK

Posted: Thu 22 Sep 2011 14:21
by Shalex
JomKippur, we have answered you at http://www.devart.com/forums/viewtopic.php?t=22037.