Connecting to multiple tables in MySQL with one call


#1

Hi! In the previous version I was told that this wasn’t possible but would like to know if it’s possible in the update.
I would like to make a call to the api and access multiple tables at once. For example my call would go to
http://domain.com/api/hit
Method : POST
Calling out different parameters:
params : {
‘company_id’ : company_id,
‘order_id’ : OrderId,
‘zip’ : Orderzip,
‘estimated_age’ :
and me get back the data but it’s located in different tables in the same db.
Is this possible?


#2

Use the ‘related’ parameter to query data in multiple tables that are related by foreign key http://wiki.dreamfactory.com/DreamFactory/Tutorials/Querying_multiple_tables_with_joins.

To query data in more than two tables, you can use stored procedures http://wiki.dreamfactory.com/DreamFactory/Tutorials/Querying_stored_procedures or you can use server-side scripts.