包含一个可预备语句的一个 C 字符串或一个主变量,可预备语句是 SELECT、INSERT、UPDATE 或者 DELETE 之一。
例子
char *stmt = "SELECT * FROM test1 WHERE a = ? AND b = ?";
EXEC SQL ALLOCATE DESCRIPTOR outdesc;
EXEC SQL PREPARE foo FROM :stmt;
EXEC SQL EXECUTE foo USING SQL DESCRIPTOR indesc INTO SQL DESCRIPTOR outdesc;