The following program converts two longs to INT8 types and displays the results. */
GBase 8s ESQL/C 编程指南 南大通用数据技术股份有限公司 - 737 -
#include
EXEC SQL include "int8.h";
char result[41];
main() { mint x; ifx_int8_t num; int4 n;
printf("IFX_INT8CVLONG Sample ESQL Program running.\n\n");
printf("Long Integer 1 = 129449233\n"); if (x = ifx_int8cvlong(129449233L, #)) { printf("Error %d in converting long to INT8\n", x); exit(1); } if (x = ifx_int8toasc(#, result, sizeof(result))) { printf("Error %d in converting INT8 to string\n", x); exit(1); } result[40] = '\0'; printf(" String for INT8 type value = %s\n", result);
n = 2147483646; /* set n */ printf("Long Integer 2 = %d\n", n); if (x = ifx_int8cvlong(n, #)) { printf("Error %d in converting long to INT8\n", x);
GBase 8s ESQL/C 编程指南 南大通用数据技术股份有限公司 - 738 -
exit(1); } if (x = ifx_int8toasc(#, result, sizeof(result))) { printf("Error %d in converting INT8 to string\n", x); exit(1); } result[40] = '\0'; printf(" String for INT8 type value = %s\n", result);
printf("\nIFX_INT8CVLONG Sample Program over.\n\n"); exit(0); } 输出 IFX_INT8CVLONG Sample ESQL Program running.
Long Integer 1 = 129449233 String for INT8 type value = 129449233 Long Integer 2 = 2147483646 String for INT8 type value = 2147483646 IFX_INT8CVLONG Sample Program over.
ARCHIVE_SNAPSHOT 是DB4AI 特性用于存档快照的接口函数。通过语法ARCHIVE SNAPSHOT 调用。生效后的快照无法参数训练等任务。 参数 类型 描述 i_schema IN NAME 快照存储的模式名字,默认 值是当前用户 i_name IN NAME 快照名称 res OUT db4ai.snapshot_name 结果