Posted by Admin test - over 10 yearsago
To Apply Join on two table in zf2 you have to include two namespaces on the your Table model
use Zend\Db\TableGateway\TableGateway;
use Zend\Db\Sql\Select;
public function fetchAll()
{
$result=$this->tableGetway->select(
function (Select $select){
$select->columns(array('*'))
->join("user","u