Input Data Conversion
The following tables describe the conversion results when updating or inserting an SQL row from data in an SQL descriptor area. These conversion rules also apply in all cases when providing values for Dynamic parameter markers from an SQL descriptor area. Each table describes the data conversion for one SQL descriptor data type or class of data types.
Conversion from SQLDACHAR
Table B–12 describes data conversion from an SQL character (SQLDACHAR) data type to all supported core Progress column data types.
Table B–12: Dynamic Input from SQL Character Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
The value of the SQL character data.
|
None.
|
DATE
|
The date value of the SQL character data.
|
SQL character data contains an invalid SQL date string.
|
DECIMAL
|
The decimal value of the string numeric in the SQL character data.
|
SQL character data contains an invalid decimal string value.
Precision of the character string numeric > 50.
Number of digits to the right of the decimal point > 15.
|
INTEGER
|
The integer value of the string numeric in the SQL character data, decimal truncated if necessary.
|
SQL character data contains an invalid decimal string value.
The truncated decimal value is > 2147483647 or < -2147483648.
|
LOGICAL
|
TRUE (1) or FALSE (0).
|
SQL character data does not contain a valid integer or decimal string value equivalent to 0 or 1.
|
Conversion from SQLDADATE
Table B–13 describes data conversion from an SQL date (SQLDADATE) data type to all supported core Progress column data types.
Table B–13: Dynamic Input from SQL Date Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
The string-formatted value of the SQL date data.
|
None.
|
DATE
|
The Progress date value of the SQL date data.
|
SQL date data contains an invalid SQL date string.
|
DECIMAL
|
Not supported.
|
Input from SQL date data attempted.
|
INTEGER
|
Not supported.
|
Input from SQL date data attempted.
|
LOGICAL
|
Not supported.
|
Input from SQL date data attempted.
|
Conversion from SQLDADEC or SQLDANUM
Table B–14 describes data conversion from an SQL decimal (SQLDADEC or SQLDANUM) data type to all supported core Progress column data types.
Table B–14: Dynamic Input from SQL Decimal Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
The value of the SQL decimal data.
|
None.
|
DATE
|
Not supported.
|
Input from SQL decimal data attempted.
|
DECIMAL
|
The decimal value of the string numeric in the SQL decimal data.
|
SQL decimal data contains an invalid decimal string value.
Precision of the SQL decimal string numeric > 50.
Number of digits to the right of the decimal point > 15.
|
INTEGER
|
The integer value of the string numeric in the SQL decimal data, decimal truncated if necessary.
|
SQL decimal data contains an invalid decimal string value.
The truncated decimal value is > 2147483647 or < -2147483648.
|
LOGICAL
|
TRUE (1) or FALSE (0).
|
SQL decimal data does not contain a valid integer or decimal string value equivalent to 0 or 1.
|
Conversion from SQLDAFLT, SQLDADBL, or SQLDAREAL
Table B–15 describes data conversion from an SQL floating-point (SQLDAFLT, SQLDADBL, or SQLDAREAL) data type to all supported core Progress column data types.
Table B–15: Dynamic Input from SQL Floating Point Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
The string-formatted value of the SQL floating-point data.
|
None.
|
DATE
|
Not supported.
|
Input from SQL floating-point data attempted.
|
DECIMAL
|
The decimal value of the SQL floating-point data.
|
None.
|
INTEGER
|
The decimal-truncated value of the SQL floating-point data.
|
The truncated decimal value is > 2147483647 or < -2147483648.
|
LOGICAL
|
TRUE (1) or FALSE (0).
|
SQL floating-point data contains a value other than 0 or 1.
|
Conversion from SQLDAINT or SQLDASML
Table B–16 describes data conversion from an SQL integer (SQLDAINT or SQLDASML) data type to all supported core Progress column data types.
Table B–16: Dynamic Input from SQL Integer Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
The string-formatted value of the SQL integer data.
|
None.
|
DATE
|
Not supported.
|
Input from SQL integer data attempted.
|
DECIMAL
|
The decimal value of the SQL integer data.
|
None.
|
INTEGER
|
The value of the SQL integer data.
|
None.
|
LOGICAL
|
TRUE (1) or FALSE (0).
|
SQL integer data contains a value other than 0 or 1.
|
Conversion from SQLDALOG
Table B–17 describes data conversion from an SQL logical (SQLDALOG) data type to all supported core Progress column data types.
Table B–17: Dynamic Input from SQL Logical Data Types
Converted to . . .
|
Value Input
|
Error Conditions
|
CHARACTER
|
0 or 1.
|
None.
|
DATE
|
Not supported.
|
Input from SQL logical data attempted.
|
DECIMAL
|
0 or 1.
|
None.
|
INTEGER
|
0 or 1.
|
None.
|
LOGICAL
|
TRUE (non-zero) or FALSE (0).
|
None.
|