Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

Platforms to show: All Mac Windows Linux Cross-Platform

SQLFieldMBS.Option(name as string) as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property SQL MBS SQL Plugin 9.3 Yes Yes Yes Yes No
Function: The string value of a specific field option.
Notes:
See for more details:
http://www.sqlapi.com/OnLineDoc/Field_setOption.html
(Read and Write computed property)

Feedback, Comments & Corrections

SQLFieldMBS.ReadLongOrLob(toConsumer as SQLDataConsumerMBS, BlockSize as Integer)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method SQL MBS SQL Plugin 9.3 Yes Yes Yes Yes No
Function: Starts reading of Long or BLob(CLob) value using the given data consumer.
Notes:
BlockSize: Size of piece of data you want to get to the consumer event.

After a command execution all output parameters are updated by their values, including Long and BLob(CLob) parameters. If you want to control piecewise reading of Long or BLob(CLob) data you should do the following:

Before a command execution set kLongOrLobReaderManual reading mode (see LongOrLobReaderMode) for Long or BLob(CLob) parameters you want to process by a data consumer. After that SQLAPI++ will skip reading output Long and BLob(CLob) parameters that you set to be read manually.
After command execution use ReadLongOrLob method for each output parameter defined to be read manually.
Note, that if the command has result set(s) (it is possible in some servers, see Server specific notes) then output parameters are available only after all result sets are completely processed using FetchNext method.

See also:

Feedback, Comments & Corrections

SQLFieldMBS.ReadLongOrLob(toFile as FolderItem)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method SQL MBS SQL Plugin 16.4 Yes Yes Yes Yes No
Function: Starts reading of Long or BLob(CLob) value to the given file.
Example:
dim cmd as SQLCommandMBS // your command
dim f as FolderItem = SpecialFolder.Desktop.Child("test.jpg")
dim field as SQLFieldMBS = cmd.Field("image")
// read blob content to binarystream
field.ReadLongOrLob(f)
Notes: May raise IOExceptions if things go wrong.

See also:

Feedback, Comments & Corrections

SQLFieldMBS.ReadLongOrLob(toStream as Writeable)
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
method SQL MBS SQL Plugin 16.4 Yes Yes Yes Yes No
Function: Starts reading of Long or BLob(CLob) value to the given writeable stream.
Example:
dim cmd as SQLCommandMBS // your command
dim f as FolderItem = SpecialFolder.Desktop.Child("test.jpg")
dim b as BinaryStream = BinaryStream.Create(f, true)
dim field as SQLFieldMBS = cmd.Field("image")
// read blob content to binarystream
field.ReadLongOrLob(b)
Notes: This allows you to read in chunks the data to a stream, e.g. binarystream, textoutputstream or socket.

See also:

Feedback, Comments & Corrections

The items on this page are in the following plugins: MBS SQL Plugin.




Links
MBS Xojo tutorial videos