Welcome Guest, Not a member yet? Register   Sign In
retrieving data from a database and re-retrieving from another database
#1

(This post was last modified: 10-24-2021, 10:42 PM by Secux.)

how to i make the following request correctly and optimized?

PHP Code:
$BusinessOwnership $this->BusinessOwnership->where('userID'session()->get('id'));

 foreach(
$BusinessOwnership as $row) {
 
$data['business_profile'] = $this->BusinessProfile->where('id'$row['BusinessID']);
 } 

in this case it does not work

$BusinessOwnership - you must return one or more results with BusinessID, then extract information from BusinessProfile by id-> BusinessID
Reply


Messages In This Thread
retrieving data from a database and re-retrieving from another database - by Secux - 10-24-2021, 12:19 PM



Theme © iAndrew 2016 - Forum software by © MyBB