⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rowset.html

📁 jave白皮书 一本很好的介绍JAVA的书籍呦
💻 HTML
📖 第 1 页 / 共 5 页
字号:
setBytes</H3><PRE>public void <B>setBytes</B>(int&nbsp;parameterIndex,                     byte[]&nbsp;x)              throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a Java array of bytes.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setDate(int, java.sql.Date)"><!-- --></A><H3>setDate</H3><PRE>public void <B>setDate</B>(int&nbsp;parameterIndex,                    java.sql.Date&nbsp;x)             throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Date value.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setTime(int, java.sql.Time)"><!-- --></A><H3>setTime</H3><PRE>public void <B>setTime</B>(int&nbsp;parameterIndex,                    java.sql.Time&nbsp;x)             throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Time value.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setTimestamp(int, java.sql.Timestamp)"><!-- --></A><H3>setTimestamp</H3><PRE>public void <B>setTimestamp</B>(int&nbsp;parameterIndex,                         java.sql.Timestamp&nbsp;x)                  throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Timestamp value.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setAsciiStream(int, java.io.InputStream, int)"><!-- --></A><H3>setAsciiStream</H3><PRE>public void <B>setAsciiStream</B>(int&nbsp;parameterIndex,                           java.io.InputStream&nbsp;x,                           int&nbsp;length)                    throws java.sql.SQLException</PRE><DL><DD>When a very large ASCII value is input to a LONGVARCHAR parameter, it may be more practical to send it via a java.io.InputStream. JDBC will read the data from the stream as needed, until it reaches end-of-file.     <P><B>Note:</B> This stream object can either be a standard Java stream object or your own subclass that implements the standard interface.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the java input stream which contains the ASCII parameter value<DD><CODE>length</CODE> - the number of bytes in the stream<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setBinaryStream(int, java.io.InputStream, int)"><!-- --></A><H3>setBinaryStream</H3><PRE>public void <B>setBinaryStream</B>(int&nbsp;parameterIndex,                            java.io.InputStream&nbsp;x,                            int&nbsp;length)                     throws java.sql.SQLException</PRE><DL><DD>When a very large binary value is input to a LONGVARBINARY parameter, it may be more practical to send it via a java.io.InputStream. JDBC will read the data from the stream as needed, until it reaches end-of-file.  <P><B>Note:</B> This stream object can either be a standard Java stream object or your own subclass that implements the standard interface.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the java input stream which contains the binary parameter value<DD><CODE>length</CODE> - the number of bytes in the stream<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setCharacterStream(int, java.io.Reader, int)"><!-- --></A><H3>setCharacterStream</H3><PRE>public void <B>setCharacterStream</B>(int&nbsp;parameterIndex,                               java.io.Reader&nbsp;reader,                               int&nbsp;length)                        throws java.sql.SQLException</PRE><DL><DD>When a very large UNICODE value is input to a LONGVARCHAR parameter, it may be more practical to send it via a java.io.Reader. JDBC will read the data from the stream as needed, until it reaches end-of-file.    <P><B>Note:</B> This stream object can either be a standard Java stream object or your own subclass that implements the standard interface.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the java reader which contains the UNICODE data<DD><CODE>length</CODE> - the number of characters in the stream<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setObject(int, java.lang.Object, int, int)"><!-- --></A><H3>setObject</H3><PRE>public void <B>setObject</B>(int&nbsp;parameterIndex,                      java.lang.Object&nbsp;x,                      int&nbsp;targetSqlType,                      int&nbsp;scale)               throws java.sql.SQLException</PRE><DL><DD><p>Set the value of a parameter using an object; use the java.lang equivalent objects for integral values. <p>The given Java object will be converted to the targetSqlType before being sent to the database. If the object is of a class implementing SQLData, the rowset should call its method writeSQL() to write it  to the SQL data stream. else If the object is of a class implementing Ref, Blob, Clob, Struct,  or Array then pass it to the database as a value of the  corresponding SQL type. <p>Note that this method may be used to pass datatabase- specific abstract data types.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - The first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - The object containing the input parameter value<DD><CODE>targetSqlType</CODE> - The SQL type (as defined in java.sql.Types) to be  sent to the database. The scale argument may further qualify this type.<DD><CODE>scale</CODE> - For java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types          this is the number of digits after the decimal.  For all other          types this value will be ignored,<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.<DT><B>See Also: </B><DD><CODE>Types</CODE></DL></DD></DL><HR><A NAME="setObject(int, java.lang.Object, int)"><!-- --></A><H3>setObject</H3><PRE>public void <B>setObject</B>(int&nbsp;parameterIndex,                      java.lang.Object&nbsp;x,                      int&nbsp;targetSqlType)               throws java.sql.SQLException</PRE><DL><DD>This method is like setObject above, but the scale used is the scale of the second parameter.  Scalar values have a scale of zero.  Literal values have the scale present in the literal.  While it is supported, it  is not recommended that this method not be called with floating point  input values.<DD><DL><DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setObject(int, java.lang.Object)"><!-- --></A><H3>setObject</H3><PRE>public void <B>setObject</B>(int&nbsp;parameterIndex,                      java.lang.Object&nbsp;x)               throws java.sql.SQLException</PRE><DL><DD><p>Set the value of a parameter using an object; use the java.lang equivalent objects for integral values. <p>The JDBC specification specifies a standard mapping from Java Object types to SQL types.  The given argument java object will be converted to the corresponding SQL type before being sent to the database. <p>Note that this method may be used to pass datatabase specific abstract data types, by using a Driver specific Java type. If the object is of a class implementing SQLData, the rowset should call its method writeSQL() to write it  to the SQL data stream. else If the object is of a class implementing Ref, Blob, Clob, Struct,  or Array then pass it to the database as a value of the  corresponding SQL type. Raise an exception if there is an ambiguity, for example, if the object is of a class implementing more than one of those interfaces.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - The first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - The object containing the input parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setRef(int, java.sql.Ref)"><!-- --></A><H3>setRef</H3><PRE>public void <B>setRef</B>(int&nbsp;i,                   java.sql.Ref&nbsp;x)            throws java.sql.SQLException</PRE><DL><DD>Set a REF(&lt;structured-type&gt;) parameter.<DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - an object representing data of an SQL REF Type</DL></DD></DL><HR><A NAME="setBlob(int, java.sql.Blob)"><!-- --></A><H3>setBlob</H3><PRE>public void <B>setBlob</B>(int&nbsp;i,                    java.sql.Blob&nbsp;x)             throws java.sql.SQLException</PRE><DL><DD>Set a BLOB parameter.<DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - an object representing a BLOB</DL></DD></DL><HR><A NAME="setClob(int, java.sql.Clob)"><!-- --></A><H3>setClob</H3><PRE>public void <B>setClob</B>(int&nbsp;i,                    java.sql.Clob&nbsp;x)             throws java.sql.SQLException</PRE><DL><DD>Set a CLOB parameter.<DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - an object representing a CLOB</DL></DD></DL><HR><A NAME="setArray(int, java.sql.Array)"><!-- --></A><H3>setArray</H3><PRE>public void <B>setArray</B>(int&nbsp;i,                     java.sql.Array&nbsp;x)              throws java.sql.SQLException</PRE><DL><DD>Set an Array parameter.<DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - an object representing an SQL array</DL></DD></DL><HR><A NAME="setDate(int, java.sql.Date, java.util.Calendar)"><!-- --></A><H3>setDate</H3><PRE>public void <B>setDate</B>(int&nbsp;parameterIndex,                    java.sql.Date&nbsp;x,                    java.util.Calendar&nbsp;cal)             throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Date value.  The driver converts this to a SQL DATE value when it sends it to the database.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setTime(int, java.sql.Time, java.util.Calendar)"><!-- --></A><H3>setTime</H3><PRE>public void <B>setTime</B>(int&nbsp;parameterIndex,                    java.sql.Time&nbsp;x,                    java.util.Calendar&nbsp;cal)             throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Time value.  The driver converts this to a SQL TIME value when it sends it to the database.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="setTimestamp(int, java.sql.Timestamp, java.util.Calendar)"><!-- --></A><H3>setTimestamp</H3><PRE>public void <B>setTimestamp</B>(int&nbsp;parameterIndex,                         java.sql.Timestamp&nbsp;x,                         java.util.Calendar&nbsp;cal)                  throws java.sql.SQLException</PRE><DL><DD>Set a parameter to a java.sql.Timestamp value.  The driver converts this to a SQL TIMESTAMP value when it sends it to the database.<DD><DL><DT><B>Parameters:</B><DD><CODE>parameterIndex</CODE> - the first parameter is 1, the second is 2, ...<DD><CODE>x</CODE> - the parameter value<DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="clearParameters()"><!-- --></A><H3>clearParameters</H3><PRE>public void <B>clearParameters</B>()                     throws java.sql.SQLException</PRE><DL><DD><P>In general, parameter values remain in force for repeated use of a RowSet. Setting a parameter value automatically clears its previous value.  However, in some cases it is useful to immediately release the resources used by the current parameter values; this can be done by calling clearParameters.<DD><DL><DT><B>Throws:</B><DD>java.sql.SQLException - if a database-access error occurs.</DL></DD></DL><HR><A NAME="execute()"><!-- --></A><H3>execute</H3><PRE>public void <B>execute</B>()             throws java.sql.SQLException</PRE><DL><DD>Fills the rowset with data.   Execute() may use the following properties: url, data source name,  user name, password, transaction isolation, and type map to create a  connection for reading data.  Execute may use the following properties to create a statement to execute a command: command, read only, maximum field size,  maximum rows, escape processing, and query timeout. If the required properties have not been set, an exception is  thrown.  If successfu

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -