RAP supports the following datatypes for message flow.
RDS datatype |
Adaptive Server datatype |
Sybase IQ datatype |
---|---|---|
uint8 |
tinyint |
tinyint |
uint16 |
unsigned smallint |
unsigned int (IQ has no unsigned smallint) |
uint32 |
unsigned int |
unsigned int |
uint64 |
unsigned bigint |
unsigned bigint |
sint8 |
smallint (Adaptive Server has no signed 8-bit integer) |
smallint (IQ has no signed 8-bit integer) |
sint16 |
smallint |
smallint |
sint32 |
int |
int |
sint64 |
bigint |
bigint |
decimal( p, s ) |
numeric( p, s ) or decimal( p, s ) Limited to precision 38. Precision must be the same on RAPCache and RAPStore. |
numeric( p, s ) or decimal( p, s ) Limited to precision 38. Precision must be the same on RAPCache and RAPStore. |
datetime |
datetime for granularity to 1/300th of a second |
timestamp |
datetime2 |
bigdatetime for granularity to 6 decimal places |
timestamp |
date |
date |
date |
time |
time |
time |
time2 |
bigtime for granularity to 6 decimal places |
timestamp |
string |
char(n) or varchar(n) n <255* |
char(n) or varchar(n) n <255* |
If you know that data for a column is always going to be shorter than a specific length, set n to a small as possible value for better performance.
For precisions up to 18 digits (approximately), to gain maximum performance , use pub_setDecimalFieldFromMantissa instead of pub_setDecimalto set decimal fields, if you can obtain the desired value in a format other than double precision.
For RAPCache microsecond time granularity, as supported in RAPStore, your application must use the bigdatetime and bigtime datatypes that support it. When using these datatypes, you must use the pub_setDateTime2Field and pub_setTime2Field methods which operate on these types.