Hello DaWei,
My code snippet belongs to an Embedded SQL file in C++. CS_CHAR is a character datatype used in Embedded SQL with Sybase and is declared within a EXEC SQL block. The actual code goes like this:
Code:
short CSQLBox::fnTest(const TCHAR *varInput)
{
exec sql begin declare section;
CS_CHAR szExtract[10];
exec sql end declare section;
szExtract[0] = _T('\0');
//szExtract array is populated by Embedded SQL query
....
//Do string comparison
for( int j=0; j<5; j++)
{
if(strcmp(szExtract, varInput)==0)
{
...
}
}
}
cheers,
sanK