IPreparedStatement.SetUnicodeStream(Int32, Stream, Int32) Method

Definition

Caution

deprecated

Sets the designated parameter to the given input stream, which will have the specified number of bytes.

[Android.Runtime.Register("setUnicodeStream", "(ILjava/io/InputStream;I)V", "GetSetUnicodeStream_ILjava_io_InputStream_IHandler:Java.Sql.IPreparedStatementInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
[System.Obsolete("deprecated")]
public void SetUnicodeStream (int parameterIndex, System.IO.Stream? x, int length);
[<Android.Runtime.Register("setUnicodeStream", "(ILjava/io/InputStream;I)V", "GetSetUnicodeStream_ILjava_io_InputStream_IHandler:Java.Sql.IPreparedStatementInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")>]
[<System.Obsolete("deprecated")>]
abstract member SetUnicodeStream : int * System.IO.Stream * int -> unit

Parameters

parameterIndex
Int32

the first parameter is 1, the second is 2, ...

x
Stream

a java.io.InputStream object that contains the Unicode parameter value

length
Int32

the number of bytes in the stream

Attributes

Exceptions

if a database error happens.

Remarks

Sets the designated parameter to the given input stream, which will have the specified number of bytes.

When a very large Unicode value is input to a LONGVARCHAR parameter, it may be more practical to send it via a java.io.InputStream object. The data will be read from the stream as needed until end-of-file is reached. The JDBC driver will do any necessary conversion from Unicode to the database char format.

The byte format of the Unicode stream must be a Java UTF-8, as defined in the Java Virtual Machine Specification.

<B>Note:</B> This stream object can either be a standard Java stream object or your own subclass that implements the standard interface.

This member is deprecated. Use setCharacterStream

Java documentation for java.sql.PreparedStatement.setUnicodeStream(int, java.io.InputStream, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to