• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
help with query
#2
Hi Stam,

The following code will work with your existing data model. It will give you an array with the data for the people that match the criteria.

Code:
local tEncounterDataQueryA, tSelectedDate, tForeignKeys, tPersonDataA
   
put cdb_Query("date", "=", tSelectedDate, "encounterDataTable", "cloud", "recordData") into tEncounterDataQueryA
   
repeat for each key xRecordID in tEncounterDataQueryA
     put tEncounterDataQueryA[xRecordID]["foreignKey"] & lf after tForeignKeys
end repeat
delete char -1 of tForeignKeys
   
put cdb_read("personDataTable", tForeignKeys, "cloud") into tPersonDataA


Let me know if you have any questions.
  Reply


Messages In This Thread
help with query - by stamatis - 10-07-2020, 11:09 PM
RE: help with query - by efrain.c - 10-08-2020, 04:56 PM
RE: help with query - by stamatis - 10-10-2020, 09:10 PM
RE: help with query - by efrain.c - 10-12-2020, 05:07 PM

Forum Jump:


Users browsing this thread: 2 Guest(s)