CDbException

CDbCommand falhou ao executar o comando SQL: SQLSTATE[HY000]: General error: 1525 Incorrect DATETIME value: ''. The SQL statement executed was: SELECT * FROM `banner` `t` WHERE (((habilitar='1') AND (local='grupo-oliveira-vagas')) AND (data_entrada <= '2024-03-19 03:38:44')) AND (data_saida IS NULL OR data_saida = '' OR data_saida = '0000-00-00 00:00:00' OR data_saida >= '2024-03-19 03:38:44' OR programado = 0) ORDER BY posicao asc LIMIT 1

/hosting/grupooliveira/public_html/extranet/yii/db/CDbCommand.php(541)

529         {
530             if($this->_connection->enableProfiling)
531                 Yii::endProfile('system.db.CDbCommand.query('.$this->getText().$par.')','system.db.CDbCommand.query');
532 
533             $errorInfo=$e instanceof PDOException ? $e->errorInfo : null;
534             $message=$e->getMessage();
535             Yii::log(Yii::t('yii','CDbCommand::{method}() failed: {error}. The SQL statement executed was: {sql}.',
536                 array('{method}'=>$method, '{error}'=>$message, '{sql}'=>$this->getText().$par)),CLogger::LEVEL_ERROR,'system.db.CDbCommand');
537 
538             if(YII_DEBUG)
539                 $message.='. The SQL statement executed was: '.$this->getText().$par;
540 
541             throw new CDbException(Yii::t('yii','CDbCommand failed to execute the SQL statement: {error}',
542                 array('{error}'=>$message)),(int)$e->getCode(),$errorInfo);
543         }
544     }
545 
546     /**
547      * Builds a SQL SELECT statement from the given query specification.
548      * @param array $query the query specification in name-value pairs. The following
549      * query options are supported: {@link select}, {@link distinct}, {@link from},
550      * {@link where}, {@link join}, {@link group}, {@link having}, {@link order},
551      * {@link limit}, {@link offset} and {@link union}.
552      * @return string the SQL statement
553      * @since 1.1.6

Stack Trace

#3
+
 /hosting/grupooliveira/public_html/britagem.php(13): CActiveRecord->find(CDbCriteria)
08 $criteria_banner->addCondition("habilitar='1'");
09 $criteria_banner->addCondition("local='grupo-oliveira-vagas'");
10 $criteria_banner->addCondition("data_entrada <= '".$data_atual."'");
11 $criteria_banner->addCondition("data_saida IS NULL OR data_saida = '' OR data_saida = '0000-00-00 00:00:00' OR data_saida >= '".$data_atual."' OR programado = 0");
12 $criteria_banner->order = 'posicao asc';
13 $banner = Banner::model()->find($criteria_banner);
14 $tit_banner = 'Banner vagas de trabalho';
15 $img_banner ="img/banner-vagas.jpg";
16 if(is_object($banner)){
17     $tit_banner = $banner->titulo;
18     $img_banner = "extranet/thumbnail/crop/1920x595/Banner/".$banner->imagem;
#4
+
 /hosting/grupooliveira/public_html/RequestManager.php(171): require_once("/hosting/grupooliveira/public_html/britagem.php")
166             Utf8::encode($html);
167             echo $html;
168             exit;
169         }
170 
171         require_once($require_file);
172         exit;
173 
174     }
175 
176 }
#5
+
 /hosting/grupooliveira/public_html/index.php(65): RequestManager->run(array("/" => "inicial.php", "/index" => "inicial.php", "/inicial" => "inicial.php", "/vaga-de-trabalho" => "trabalhe-conosco.php", ...))
60 
61 
62     '/(?P<pag>\S+)'=>'inicial.php',
63 );
64 
65 $request_manager->run($rotas);
66 ?>
2024-03-19 03:38:44 Apache Yii Framework/1.1.13