我的PHP代码是:
$company = $qb->select("c")
->from("CRMBundle:TblCompanyDomain","cd")
->join("cd.company","c")
->leftJoin("CRMBundle:TblCompanyAddress",
"ca",
"WITH",
"ca.company = c")
->join("ca.country","cc")
->where($qb->expr()->andX(
$qb->expr()->in("cd.domain",":domain"),
$qb->expr()->eq("c.channel",":channel_id")
))
->setParameters($parameters)
->setMaxResults(1)
->getQuery()
->getOneOrNullResult();
结束收到的DQL代码是:
SELECT
c
FROM
CRMBundle:TblCompanyDomain cd
INNER JOIN cd.company c
LEFT JOIN CRMBundle:TblCompanyAddress ca WITH ca.company = c
INNER JOIN ca.country cc
WHERE
cd.domain IN(:domain) AND
c.channel = :channel_id
执行此查询时,我收到了此错误:
[Syntax Error] line 0, col 44: Error: Expected end of string, got 'I'
enter code here
我看不到任何语法错误。问题在哪里?
我的Symfony版本:2.6.11
我的学说版本:2.2
答案 0 :(得分:0)
foreach(GridViewRow row in grdMappingList.Rows)
{
DropDownList ddgvOpp = (DropDownList) row.FindControl("ddgvOpp");
// ...
}
我认为你需要c.something
答案 1 :(得分:0)
我已经从注释改为yml我的学说orm映射和修复问题。
我经历了很多次同样的问题并且理解了真正的问题。当我使用带有utf-8的Doctrine注释时,解决了这个问题。可能是因为土耳其语是utf-8。因为较低的“ı”charachter的资本是“我”而较低的“i”carachter的资本是“İ”。