That's the full error code I had:

I did find that in the APP\app_model.php, line 15 there was "execute"
so I just changed it to query and it was fixed.


Thanks Dr.Loboto


Warning (512): SQL Error: 1064: You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the
right syntax to use near '' at line 1 [CORE\cake\libs\model\datasources
\dbo_source.php, line 525]

Code | Context

$sql    =       "execute"
$error  =       "1064: You have an error in your SQL syntax; check the manual
that corresponds to your MySQL server version for the right syntax to
use near '' at line 1"
$out    =       null

            $out = null;
            if ($error) {
                trigger_error("<span style = \"color:Red;text-
align:left\"><b>SQL Error:</b> {$this->error}</span>",
E_USER_WARNING);

DboSource::showQuery() - CORE\cake\libs\model\datasources
\dbo_source.php, line 525
DboSource::execute() - CORE\cake\libs\model\datasources
\dbo_source.php, line 201
DboSource::fetchAll() - CORE\cake\libs\model\datasources
\dbo_source.php, line 337
DboSource::query() - CORE\cake\libs\model\datasources\dbo_source.php,
line 298
Model::call__() - CORE\cake\libs\model\model.php, line 437
Overloadable::__call() - CORE\cake\libs\overloadable_php5.php, line 52
Noticia::execute() - APP\app_model.php, line 15
AppModel::__construct() - APP\app_model.php, line 15
ClassRegistry::init() - CORE\cake\libs\class_registry.php, line 140
Controller::loadModel() - CORE\cake\libs\controller\controller.php,
line 503
Controller::constructClasses() - CORE\cake\libs\controller
\controller.php, line 457
Dispatcher::_invoke() - CORE\cake\dispatcher.php, line 207
Dispatcher::dispatch() - CORE\cake\dispatcher.php, line 194
require - APP\webroot\index.php, line 88
[main] - CORE\index.php, line 61

Query: execute

Query: execute

On 17 jul, 03:31, "Dr. Loboto" <[email protected]> wrote:
> Open this error message and inspect stack trace there. You'll see
> which model/controller/behavior still uses execute() method instead of
> query() one.
>
> On Jul 17, 3:06 am, "[email protected]" <[email protected]>
> wrote:
>
> > HI,
>
> > I'm using cake_1.2.3.8166 version. I get this error:
>
> > Warning (512): SQL Error: 1064: You have an error in your SQL syntax;
> > check the manual that corresponds to your MySQL server version for the
> > right syntax to use near '' at line 1 [CORE\cake\libs\model\datasources
> > \dbo_source.php, line 525]
>
> > Query: execute
>
> > Query: execute
>
> > I did change all the execute() to query(), but the problem is still
> > there.
>
> > Any ideas?
>
> > Regards,

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to