[Mono-list] System.Data.OracleClient on z/Linux
Daniel Morgan
monodanmorg at yahoo.com
Mon Feb 11 13:36:44 EST 2008
I don't think the OracleClient provider has been
tested with z/Linux. The provider has mainly been
tested on 32-bit x86 platforms (little-endian), such
as, Linux, Windows, and Solaris x86.
Some questions:
1. is z/Linux big-endian or little-endian?
2. is z/Linux 32-bit or 64-bit?
Most of the problems you will find with the provider
is with the marshalling code using DllImport into the
OCI library -- especially the marshalling of integer
values.
--- Edwin Kim <EKIM at transitchicago.com> wrote:
> Hello mono-list,
>
> I tried to access the Oracle Data Source using
> System.Data.OracleClient from z/linux (s390x),
> and I get this Error-Message:
>
>
> Unhandled Exception: System.NullReferenceException:
> Object reference not set to an instance of an object
> at
>
System.Data.OracleClient.Oci.OciStatementHandle.Prepare
> (System.String commandText) [0x00000]
> at
>
System.Data.OracleClient.OracleCommand.PrepareStatement
> (System.Data.OracleClient.Oci.OciStatementHandle
> statement) [0x00000]
> at
> System.Data.OracleClient.OracleCommand.ExecuteReader
> (CommandBehavior behavior) [0x00000]
> at
> System.Data.OracleClient.OracleCommand.ExecuteReader
> () [0x00000]
> at (wrapper remoting-invoke-with-check)
> System.Data.OracleClient.OracleCommand:ExecuteReader
> ()
> at Test.Main (System.String[] args) [0x00000]
>
> the code:
> using System;
> using System.Data;
> using System.Data.OracleClient;
>
> public class Test
> {
> public static void Main (string[] args)
> {
> string connectionString =
> "Data Source=wpsdb;" +
> "User ID=test;" +
> "Password=test;";
> OracleConnection dbcon = null;
> dbcon = new OracleConnection
> (connectionString);
> dbcon.Open ();
>
> OracleCommand dbcmd = dbcon.CreateCommand ();
> string sql = "SELECT * FROM dual";
> dbcmd.CommandText = sql;
> OracleDataReader reader = dbcmd.ExecuteReader
> ();
> // clean up
> reader.Close ();
> reader = null;
> dbcmd.Dispose ();
> dbcmd = null;
> dbcon.Close ();
> dbcon = null;
> }
> }
>
>
> OS: z/linux (sles10 sp1) with
> mono-data-oracle-1.2.2-12.12 and installed Oracle
> instantclient 10.2
>
> compiled: mcs test1.cs /r:System.Data.dll
> /r:System.Data.OracleClient.dll
> run: mono test1.exe
>
> Did I forget something ?
> or will the System.Data.OracleClient not work with
> on z/Linux environment?
>
> Best regards,
> Edwin
>
> > _______________________________________________
> Mono-list maillist - Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
More information about the Mono-list
mailing list