SQL_SET_LOB_UC¶
Applies to: ORAFlex SQLFlex MYSQLFlex PGFlex DB2Flex
This command replaces whatever is currently in a LOB Field with the uChar[] passed. It writes to a client side buffer. It can be used to Write an arbitrary amount of data into a LOB. If passed an empty uChar[], it will remove all the contents of the LOB. If you wish to Set a LOB back to NULL, please use the SQL_SET_LOB_NULL command. NOTE: Unlike the previous call LOB_WRITE, this call does not perform the Save. This must be done separately.
Syntax
SQL_SET_LOB_UC {FileName.FieldName} to {variable}
Parameter |
Description |
---|---|
FileName |
The name of the file containing the LOB field |
FieldName |
The name of the LOB field being set |
variable |
The variable to use to set the field’s value. Must be a uChar[] |
Example
uChar[] ucData
Clear Customer
Move iID to Customer.ID
Find Eq Customer by Index.1
If (Found) Begin
Direct_Input "C:\bigFile.xml"
Reread Customer
SQL_SET_LOB_UC Customer.Comments to (ResizeArray(ucData, 0))
set_channel_position 0 to -1
get_channel_position 0 to iSize
Read_Block ucData iSize
SQL_SET_LOB Customer.Comments to ucData
Saverecord Customer
Unlock
Close_Input
End
SQL_LOB_TRUNCATE_UC