Code: Select all
QDict->SQL->Strings[0]="SELECT ID, DTON, WHAT, RC, AUTO, DUREE, substr(command, 1, {fn LOCATE('''',command) } -1) as pgm FROM thetable";
QDict->DataTypeMap->AddFieldNameRule("PGM", ftWideString);
DBMonitor: sql translation is correct.
This query is source of a TCrDBGrid.
Query from db monitor copied to pgadmin gives the good results.
Problem in postgres: only 20 first chars of substr(command, 1, {fn LOCATE('''',command) } -1) are displayed in the grid. (only in postgres, connected to oracle display is fine!!!!).
Any hint?