$select->columns(array('TableReservationId', 'TableId',
'ReservationDate', 'StartTime',
'NumberOfGuests', 'AdditinalInfo',
'StaffID', 'MerchantId', 'cust_id'
)
);
$select->join($cus, "$dtr.cust_id=$cus.cust_id",
array('cust_firstName','cust_lastName'),
'left');
$select->join($mer, "$dtr.MerchantId=$mer.MerchantId",
array('FirstName','LastName'),
'left');
$select->join($staff, "$dtr.StaffID=$staff.StaffID",
array('FirstName','LastName'),
'left');
这是我想要concat (FirstName,'' ,LastName ) as customer_name
的查询
concat (FirstName,'' ,LastName ) as Employee_name
我该怎么做?
答案 0 :(得分:0)
你可以不在选择中吗?如:
(FirstName + '' + LastName) as Employee_Name