Initialization of host variables in C and C++ embedded SQL applications
In C and C++ declare
sections, you can declare and initialize multiple variables on a single
line. However, you must initialize variables using the "=" symbol,
not parentheses.
The following example shows the correct and incorrect methods of
initialization in a declare section:
EXEC SQL BEGIN DECLARE SECTION;
short my_short_2 = 5; /* correct */
short my_short_1(5); /* incorrect */
EXEC SQL END DECLARE SECTION;