зеркало из https://github.com/mono/mail-archives.git
171 строка
5.6 KiB
HTML
171 строка
5.6 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE> [Mono-bugs] [Bug 430413] New: System.Data.OracleClient:
|
|
</TITLE>
|
|
<LINK REL="Index" HREF="index.html" >
|
|
<LINK REL="made" HREF="mailto:mono-bugs%40lists.ximian.com?Subject=%5BMono-bugs%5D%20%5BBug%20430413%5D%20New%3A%20System.Data.OracleClient%3A&In-Reply-To=">
|
|
<META NAME="robots" CONTENT="index,nofollow">
|
|
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
|
|
<LINK REL="Previous" HREF="080054.html">
|
|
<LINK REL="Next" HREF="080057.html">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#ffffff">
|
|
<H1>[Mono-bugs] [Bug 430413] New: System.Data.OracleClient:</H1>
|
|
<B>bugzilla_noreply at novell.com</B>
|
|
<A HREF="mailto:mono-bugs%40lists.ximian.com?Subject=%5BMono-bugs%5D%20%5BBug%20430413%5D%20New%3A%20System.Data.OracleClient%3A&In-Reply-To="
|
|
TITLE="[Mono-bugs] [Bug 430413] New: System.Data.OracleClient:">bugzilla_noreply at novell.com
|
|
</A><BR>
|
|
<I>Sat Sep 27 12:51:45 EDT 2008</I>
|
|
<P><UL>
|
|
<LI>Previous message: <A HREF="080054.html">[Mono-bugs] [Bug 430409] New: MONO quits when accessing MySQL TINYTEXT with CHARACTER SET ascii
|
|
</A></li>
|
|
<LI>Next message: <A HREF="080057.html">[Mono-bugs] [Bug 430450] New: ** ERROR **: MVAR 2 (S) cannot be expanded in this context with 2 instantiations
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#80056">[ date ]</a>
|
|
<a href="thread.html#80056">[ thread ]</a>
|
|
<a href="subject.html#80056">[ subject ]</a>
|
|
<a href="author.html#80056">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
<HR>
|
|
<!--beginarticle-->
|
|
<PRE><A HREF="https://bugzilla.novell.com/show_bug.cgi?id=430413">https://bugzilla.novell.com/show_bug.cgi?id=430413</A>
|
|
|
|
|
|
Summary: System.Data.OracleClient:
|
|
Product: Mono: Class Libraries
|
|
Version: 1.9
|
|
Platform: x86
|
|
OS/Version: RHEL 4
|
|
Status: NEW
|
|
Severity: Major
|
|
Priority: P5 - None
|
|
Component: Sys.Data
|
|
AssignedTo: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">bnc-blr-team-mono at forge.provo.novell.com</A>
|
|
ReportedBy: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">ernezto at gmail.com</A>
|
|
QAContact: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">mono-bugs at lists.ximian.com</A>
|
|
Found By: Development
|
|
|
|
|
|
Description of Problem:
|
|
I'm trying to retrieve a BLOB field from a table in an Oracle database, convert
|
|
it or cast it to byte[] and save it to the hard disk, the content of that field
|
|
is a a PDF document, but I'm getting an exception. This code works OK on MS
|
|
NET 1.1, I tried several ways to get the byte[] from the OracleDataReader but
|
|
always get the same exception.
|
|
|
|
Steps to reproduce the problem:
|
|
|
|
This is one of the options I use to retrieve the byte[]... if the
|
|
OracleDataReader has rows, it will have just only one... (I mean in my case)
|
|
|
|
byte[] img;
|
|
if (rd.HasRows)
|
|
{
|
|
rd.Read();
|
|
img = (byte[])rd["IMAGEN"];
|
|
caminoImagen = directorio + idImagen.ToString() + ".pdf";
|
|
fs = new FileStream(caminoImagen, FileMode.Create, FileAccess.Write);
|
|
fs.Write(img, 0, img.Length);
|
|
fs.Close();
|
|
}
|
|
|
|
|
|
Actual Results:
|
|
I got an exception (check details on Additional Information), the exception is
|
|
a System.NullReferenceException: Object reference not set to an instance of an
|
|
object, BUT I debugged the method and the OracleDataReader do have value there,
|
|
an array of bytes, I don't know why the cast to byte[] don't work in Mono.
|
|
|
|
Expected Results:
|
|
Get the BLOB field value converted to byte[]...
|
|
|
|
How often does this happen?
|
|
Always.
|
|
|
|
Additional Information:
|
|
|
|
System.NullReferenceException: Object reference not set to an instance of an
|
|
object
|
|
at System.Data.OracleClient.Oci.OciLobLocator.GetLength (Boolean binary)
|
|
[0x00000]
|
|
at System.Data.OracleClient.OracleLob.get_Length () [0x00000]
|
|
at System.Data.OracleClient.OracleLob.get_Value () [0x00000]
|
|
at (wrapper remoting-invoke-with-check)
|
|
System.Data.OracleClient.OracleLob:get_Value ()
|
|
at System.Data.OracleClient.OracleDataReader.GetValue (Int32 i) [0x00000]
|
|
at (wrapper remoting-invoke-with-check)
|
|
System.Data.OracleClient.OracleDataReader:GetValue (
|
|
int)
|
|
at System.Data.OracleClient.OracleDataReader.get_Item (System.String name)
|
|
[0x00000]
|
|
at (wrapper remoting-invoke-with-check)
|
|
System.Data.OracleClient.OracleDataReader:get_Item (
|
|
string)
|
|
at SARENWS.Negocio.Documento.ObtenerPDF (System.String cadenaConexion, Int32
|
|
tipoOficina,
|
|
System.String id) [0x00000]
|
|
|
|
|
|
--
|
|
Configure bugmail: <A HREF="https://bugzilla.novell.com/userprefs.cgi?tab=email">https://bugzilla.novell.com/userprefs.cgi?tab=email</A>
|
|
------- You are receiving this mail because: -------
|
|
You are the QA contact for the bug.
|
|
</PRE>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--endarticle-->
|
|
<HR>
|
|
<P><UL>
|
|
<!--threads-->
|
|
<LI>Previous message: <A HREF="080054.html">[Mono-bugs] [Bug 430409] New: MONO quits when accessing MySQL TINYTEXT with CHARACTER SET ascii
|
|
</A></li>
|
|
<LI>Next message: <A HREF="080057.html">[Mono-bugs] [Bug 430450] New: ** ERROR **: MVAR 2 (S) cannot be expanded in this context with 2 instantiations
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#80056">[ date ]</a>
|
|
<a href="thread.html#80056">[ thread ]</a>
|
|
<a href="subject.html#80056">[ subject ]</a>
|
|
<a href="author.html#80056">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
|
|
<hr>
|
|
<a href="http://lists.ximian.com/mailman/listinfo/mono-bugs">More information about the mono-bugs
|
|
mailing list</a><br>
|
|
</body></html>
|