I need to concatenate some fields :
Code: Select all
SELECT
trim(Trim(Nom_Pilote || ' ' || Prenom_Pilote) || ' ' || '(' || Id_Pilote || ')') as Nom_Pilote
FROM
Pilotes
order by
Nom_Pilote
Code: Select all
SELECT
trim(Trim(Nom_Pilote || ' ' || Prenom_Pilote) || ' ' || '(' || Id_Pilote || ')') as Nom_Pilote
FROM
Pilotes
order by
Nom_Pilote
Code: Select all
UniQuery.DataTypeMap.AddFieldNameRule('Nom_Pilote', ftWideString);
UniQuery.Open;
I've tried this but field type is still maped to ftWideMemo.You can use CAST in your SQL expression or data type mapping in UniQuery
That did the trick.When using concatenation, SQLite returns the Unknown data type, therefore we map fields of this type to ftWideMemo. You can use the DataTypeMapping technology to map the field type to a required type.