Replication Agent for UDB processes transactions and passes data to the primary Replication Server.
The primary Replication Server uses the datatype formats specified in the replication definition to receive the data from Replication Agent for UDB.
The following table describes the default conversion of UDB datatypes to Sybase datatypes.
For each datatype in Table 3-2, lengths in the second column are described as:
Character datatypes – maximum number of bytes.
Graphic datatypes – maximum number of characters.
Numeric datatypes – range from smallest to largest values.
Temporal datatypes – range from earliest time to latest time.
UDB datatype |
UDB length/range |
Sybase datatype |
Sybase length/range |
Notes |
---|---|---|---|---|
BIGINT |
-9,223,372,036, 854,775,808 to 9,223,372,036, 854,775,807 |
bigint |
10-38 to 1038, 38 significant digits |
|
BLOB |
variable length, 2GB, binary data |
image |
2GB |
|
CHAR |
254 bytes |
char |
32K |
|
CHAR FOR BIT DATA |
254 bytes, binary data |
binary |
32K |
|
CLOB |
variable length, 2GB, character data |
text |
2GB |
|
DATE |
0001-01-01 to 9999-12-31 |
char, date, or datetime |
32K (char) |
If the pdb_convert_datetime parameter is false, DATE values are sent as char datatype strings. If the pdb_convert_datetime parameter is true, DATE values are converted to date or datetime values. |
DBCLOB |
variable length, 2GB, double-byte character data |
unitext or image |
2GB |
For Replication Server 15.0 and later versions, DBCLOB maps to unitext. For earlier versions of Replication Server, DBCLOB maps to image. |
DECFLOAT(16) |
8 bytes, -9.999999999999999 x 10384 to -1.0 x 10-383 and1.0 x 10-383 to 9.999999999999999 x 10384 |
float |
Precision and range corresponds to a C double datatype, approximately 16 significant digits |
Some loss of precision may result. |
DECFLOAT(34) |
16 bytes, -9.9999999999999999 99999999999999999 x 106144 to -1.0 x 10-6143 and 1.0 x 10-6143 to 9.999999999999999999999999999999999 x 106144 |
float |
Precision and range corresponds to a C double datatype, approximately 16 significant digits |
Some loss of precision may result. |
DECIMAL |
-1031+1 to 1031-1, 31 digits of precision |
decimal |
10-38 to 1038, 38 significant digits |
|
DOUBLE |
See FLOAT. |
|||
FLOAT |
8 bytes, -1.79769308 to 1.79769308 |
float |
Precision and range corresponds to a C double datatype, approximately 16 significant digits |
Extremely small values are truncated to 16 digits to the right of the decimal. Extremely large values retain their precision. |
GRAPHIC |
127 characters, double-byte character data |
unichar |
32K |
|
INTEGER |
-2,147,483,648 to 2,147,483,647 |
int |
-2,147,483,648 to 2,147,483,647 |
|
LONG VARCHAR |
variable length, 32,700 bytes, character data |
text |
2GB |
|
LONG VARCHAR FOR BIT DATA |
32,700 bytes, binary data |
image |
2GB |
|
LONG VARGRAPHIC |
16,350 characters, double-byte character data |
unitext or image |
2GB |
For Replication Server 15.0 and later versions, LONG VARGRAPHIC maps to unitext. For earlier versions of Replication Server, LONG VARGRAPHIC maps to image. |
NUMERIC (synonym for DECIMAL) |
See DECIMAL. |
|||
REAL |
-3.40238 to 3.40238 |
decimal |
10-38 to 1038, 38 significant digits |
|
SMALLINT |
-32,768 to 32,767 |
smallint |
-32,768 to 32,767 |
|
TIME |
00:00:00 to 24:00:00 |
char, time, or datetime |
32K (char) |
|
TIMESTAMP |
0001-01-01-00.00.00.000000 to 9999-12-31-24.00.00.000000 |
char or datetime |
32K (char) |
If the pdb_convert_datetime parameter is false, TIMESTAMP values are sent as char datatype strings. If the pdb_convert_datetime parameter is true, TIMESTAMP values are converted to datetime values. |
VARCHAR |
32,672 bytes |
varchar |
32K |
|
VARCHAR FOR BIT DATA |
32,672 bytes, binary data |
varbinary |
32K |
|
VARGRAPHIC |
16,336 characters, double-byte character data |
univarchar |
32K |