$fetch data into row variable

Martin Obongita martin.obongita at yahoo.com
Fri Sep 30 16:43:30 UTC 2022

Hi $OSListers,
I have searched through the list archives for the fetch command.
I have not found a closer answer to the problem I have.
I have this method below in a tableclass to fetch data from postgresql.

If $cinst.$type=kRow

Do $cinst.$select("WHERE ",iPrimaryKey," =",pFetchID)
Do $cinst.$fetch(iDataRow) Returns lFetchOk
End If
Quit method lFetchOk=kFetchOk
If I loop through the lines and check the variables:
iPrimaryKey has a value
pFetchID has a value
lFetchOk returns flag True
But iDataRow is empty
What is the correct syntax to fetch data into a row variable with a where clause?
Grateful as always for all your kind helps.

More information about the omnisdev-en mailing list