Microsoft SDK for Java

getString

The getString method of the Recordset class returns the Recordset as a string. getString has the following signatures:

getString(int StringFormat)
getString(int StringFormat, int NumRows)
getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter)
getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter, String NullExpr)

getString(int StringFormat)

Returns the Recordset as a string.

Syntax

public String getString(int StringFormat);

Return Value

Returns the Recordset as a string-valued Variant (BSTR).

Parameters

StringFormat An AdoEnums.StringFormat value that specifies how the Recordset should be converted to a string. The RowDelimiter, ColumnDelimiter, and NullExpr parameters are used with only a StringFormat of CLIPSTRING.

getString(int StringFormat, int NumRows)

Returns the Recordset as a string.

Syntax

public String getString(int StringFormat, int NumRows);

Return Value

Returns the Recordset as a string-valued Variant (BSTR).

Parameters

StringFormat An AdoEnums.StringFormat value that specifies how the Recordset should be converted to a string. The RowDelimiter, ColumnDelimiter, and NullExpr parameters are used with only a StringFormat of CLIPSTRING.
NumRows The number of rows in the recordset to convert. If NumRows is not specified or if it is greater than the total number of rows in the recordset, all the rows in the recordset are converted.

getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter)

Returns the Recordset as a string.

Syntax

public String getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter);

Return Value

Returns the Recordset as a string-valued Variant (BSTR).

Parameters

StringFormat An AdoEnums.StringFormat value that specifies how the Recordset should be converted to a string. The RowDelimiter, ColumnDelimiter, and NullExpr parameters are used only with a StringFormat of CLIPSTRING.
NumRows The number of rows in the recordset to convert. If NumRows is not specified, or if it is greater than the total number of rows in the recordset, then all the rows in the recordset are converted.
ColumnDelimiter A delimiter used between columns if specified, otherwise the TAB character.
RowDelimiter A delimiter used between rows if specified, otherwise the CARRIAGE RETURN character.

getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter, String NullExpr)

Returns the Recordset as a string.

Syntax

public String getString(int StringFormat, int NumRows, String ColumnDelimiter, String RowDelimiter, String NullExpr);

Return Value

Returns the Recordset as a string-valued Variant (BSTR).

Parameters

StringFormat An AdoEnums.StringFormat value that specifies how the Recordset should be converted to a string. The RowDelimiter, ColumnDelimiter, and NullExpr parameters are used only with a StringFormat of CLIPSTRING.
NumRows The number of rows in the recordset to convert. If NumRows is not specified, or if it is greater than the total number of rows in the recordset, all the rows in the recordset are converted.
ColumnDelimiter A delimiter used between columns if specified, otherwise the TAB character is used.
RowDelimiter A delimiter used between rows if specified, otherwise the CARRIAGE RETURN character is used.
NullExpr An expression used in place of a NULL value if specified, otherwise the empty string is used.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.