->andWhere("(mdso.xcode IS NOT NULL OR mdsh.xcode IS NOT NULL)");
$this->setExpectedException('Doctrine\DBAL\Query\QueryException',"The given alias 'ol' is not part of any FROM clause table. The currently registered FROM-clause aliases are: l");
$qb->select('COUNT(DISTINCT news.id)')
->from('cb_newspages','news')
->innerJoin('news','nodeversion','nv','nv.refId = news.id AND nv.refEntityname=\'News\'')
$this->setExpectedException('Doctrine\DBAL\Query\QueryException',"The given alias 'invalid' is not part of any FROM or JOIN clause table. The currently registered aliases are: news, nv, nt, n.");