在我的 prestashop 联系表中存在此代码
SELECT *
FROM '._DB_PREFIX_.'contact c
LEFT JOIN '._DB_PREFIX_.'contact_lang cl ON c.id_contact = cl.id_contact
WHERE cl.id_lang = '.(int)($id_lang).'
ORDER BY name ASC
创建此查询
SELECT *
FROM ava_contact c
LEFT JOIN ava_contact_lang cl ON c.id_contact = cl.id_contact
WHERE cl.id_lang =6
ORDER BY name ASC
LIMIT 0 , 30
并显示正常结果
但是当 DB 类执行此代码时
Db::getInstance(_PS_USE_SQL_SLAVE_)->ExecuteS('SELECT *
FROM '._DB_PREFIX_.'contact c
LEFT JOIN '._DB_PREFIX_.'contact_lang cl ON c.id_contact = cl.id_contact
WHERE cl.id_lang = '.(int)($id_lang).'
ORDER BY name ASC');
除了“名称”字段中显示的所有值,所有值都是空字符串,嗯,这是错误的部分?
谢谢,