• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
help with query
#1
Hi all,
I’m trying to convert an existing project from a relational database.

I’m hoping I can get some help constructing a query that’s fairly straightforward in SQL...

In this scenario there are 3 tables:
- table 1 has a list of dates
- table 2 has encounter data that includes a foreign key for person and links to table 1 by date (table1.date = table2.date)
- table 3 has person data and links to table 2 with personID (table2.personID = table3.personID)

So basically selecting a date in from table 1 should retrieve all encounters in table 2 with the same date and in each retrieved result, the personID foreign key should retrieve person data from table 3 when presenting the data.

in SQL i’d just use a SELECT with JOIN statements to retrieve this in one go.

Is this feasible with liveCloud? Or would i need to construct an array running 2 separate queries?
Alternatively, should the data structure change to include all person data in the encounter table for example?

grateful for any pointers/suggestions...
  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)