[Mono-bugs] [Bug 79284][Nor] New - [PATCH] OracleClient uses CurrentCulture to communicate with OCI

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Sep 5 10:40:20 EDT 2006


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by skolima at gmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=79284

--- shadow/79284	2006-09-05 10:40:20.000000000 -0400
+++ shadow/79284.tmp.12871	2006-09-05 10:40:20.000000000 -0400
@@ -0,0 +1,49 @@
+Bug#: 79284
+Product: Mono: Class Libraries
+Version: 1.1
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 001 One hour
+Priority: Normal
+Component: Sys.Data
+AssignedTo: tsenganal at novell.com                            
+ReportedBy: skolima at gmail.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Summary: [PATCH] OracleClient uses CurrentCulture to communicate with OCI
+
+Description of Problem:
+
+When locale of the Oracle database differs from the one mono uses, every
+attempt at passing culture-sensitive data fails.This is because mono
+(wrongly) uses ToString() / ToString(CultureInfo.CurrentCulture) for
+converting data to strings it passes to OCI.
+
+
+Steps to reproduce the problem:
+1. Set Oracle database (server) to use invariant culture.
+2. Set LANG and LC_ALL to, for example, pl_PL (Poland uses , instead of .
+as decimal separator).
+3. Try to insert or select a double or decimal.
+
+Actual Results:
+
+Oracle exception 'invalid number'
+
+Expected Results:
+
+Query runs without problems.
+
+How often does this happen? 
+
+Always when locales are incompatible.
+
+Additional Information:
+
+It is possible to query the Oracle database for NLS info it uses. There are
+some traces in System.Data.OracleClient of attempts to utilize this logic.
+However, they are incomplete. An attached path makes use of GetNlsInfo() to
+provide culture-safe numericals handling.


More information about the mono-bugs mailing list