You are not logged in.
Ab, in the code below I am using the RetrieveDocVariantArray function to perform a database search to bring tables's partial fields.
I need too bring a custom virtual string field with contatenated content. See the following situations:
// property ID, nome without virtual field concatenation, executes normally.
vPaineis := GlobalRepository.Orm.RetrieveDocVariantArray(TPainel, '',
'(IdProjeto=?)',
[pId],
'ID ,Nome');
// property RowID concatenated with a string, executes normally.
vPaineis := GlobalRepository.Orm.RetrieveDocVariantArray(TPainel, '',
'(IdProjeto=?)',
[pId],
'RowID ,Nome, "/Projeto/" || RowId AS LINK');
// property ID concatenated with a string, an error occurs. i would like use this way
vPaineis := GlobalRepository.Orm.RetrieveDocVariantArray(TPainel, '',
'(IdProjeto=?)',
[pId],
'ID ,Nome, "/Projeto/" || ID AS LINK');
I need this field to make some type of HATEOAS https://en.wikipedia.org/wiki/HATEOAS
Offline
Are you using an external DB?
My guess is that such requests is using virtual tables.
In such SQLIte3 virtual tables, there is no ID but only RowID field - this is a SQLite3 limitation.
Offline
Where i found help about The vantages to use sqlite ou external DB. Im using postgree database.
Offline