Join
This example shows the usage of Join method
First Table
first_id | name |
---|---|
1 | John |
2 | Marry |
3 | Peter |
4 | Donald |
Second Table
second_id | income |
---|---|
1 | $50,000 |
2 | $60,000 |
3 | $100,000 |
4 | $80,000 |
$join = $this->dataStore("first")->join($this->dataStore("second"),array("first_id"=>"second_id"));
first_id | name | second_id | income |
---|---|---|---|
1 | John | 1 | $50,000 |
2 | Marry | 2 | $60,000 |
3 | Peter | 3 | $100,000 |
4 | Donald | 4 | $80,000 |