DeChunkText function
Syntax
DeChunkText(table_name, seq_field, data_field, &array_of_keys, &array_of_key_datatypes, &array_of_key_values)
Description
Use the DeChunkText function to read the chunks created by the ChunkText function from a database table and assemble them back into a long text string.
Parameters
| Parameter | Description |
|---|---|
|
table_name |
Specify the name of the database table as a string. This table stores the chunks created by ChunkText. |
|
seq_field |
Specify the name of the field that stores the sequence number for each chunk as a string. |
|
data_field |
Specify the name of the field that stores the data chunks as a string. |
|
&array_of_keys |
Specify key field names as an array of string. |
|
&array_of_key_datatypes |
Specify the types for the key fields as an array of string. See below. |
|
&array_of_key_values |
Specify the key field values as an array of string. |
The values for &array_of_key_datatypes can be as follows:
| Value | Description |
|---|---|
|
STR |
String value |
|
CHAR |
Single character |
|
LONGTEXT |
Long text value |
|
DATE |
Date value |
|
TIME |
Time value |
|
DATETIME |
Date/time value |
|
INT |
Integer value |
|
SHORT |
Short integer value |
|
LONG |
Long integer value |
|
DOUBLE |
Double-sized integer value |
Returns
A string.
Example
Local array of string &key_names;
Local array of string &keyfdatatypes;
Local array of string &key_vals;
Local string &text;
&tablename = "PSPCMTXT";
&seq_fld = "SEQNUM";
&data_fld = "PEOPLECODE";
&key_names = CreateArray("OBJECTID1", "OBJECTVALUE1", "OBJECTID2", "OBJECTVALUE2",⇒
"OBJECTID3", "OBJECTVALUE3");
&keyfdatatypes = CreateArray("INT", "STR", "INT", "STR", "INT", "STR");
&key_vals = CreateArray("1", "PSTRANSFRM_WRK", "2", "IB_TRANSFORM_PB", "12",⇒
"FieldChange");
&text = DeChunkText(&tablename, &seq_fld, &data_fld, &key_names, &keyfdatatypes,⇒
&key_vals);
Related Topics