$loadcols $colcount

Martin Obongita martin.obongita at yahoo.com
Mon Apr 18 14:51:02 UTC 2022


 Hi Kelly,
I have successfully defined a list from SQL using:
Do iDataList.$definefromsqlclass(iTableClassRef,lTableClassColsRow)


I have the SQL statement shown below in a table class to get data from Postgres to my iDataList:

Begin statement

Sta:Select c05_code,c05_name,c05_activestatus_linenum,c05_active_from,c05_active_to,c05_economicregion_linenum,c05_picture,c05_id

Sta:From c05_countries_pry

If pSearchStatus

Sta:Where c05_activestatus_linenum = @[pSearchActiveStatusLineNum]

End If

Sta:Order By c05_code

End statement

Get statement lSqlStmt


How do I use the columns defined in iDataList, in a PostgreSQL statement, to "select"?
Rgds, Martin.





    On Monday, April 18, 2022, 04:21:36 PM GMT+3, Kelly Burgess <kellyb at montana.com> wrote:  
 
 Hi Martin,

>Difference:$cols.$add versus $addcols

I wasn't aware of $addcols.  According to the docs it's an extensible version of $cols.$add.

  https://omnis.net/developers/resources/onlinedocs/Programming/06listprog.html#adding-columns

"..can be used to add one or more columns to a list or row variable, so the parameter count must always be a multiple of four."

Kelly
_____________________________________________________________
Manage your list subscriptions at https://lists.omnis-dev.com
Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com 
  


More information about the omnisdev-en mailing list