I am running a Task from the CLI, and at a $this->Model->field query I get
Fatal error: Class 'String' not found in /home/nagyv/workspace/cakephp1.2/cake/libs/model/datasources/dbo_source.php on line 1455 I've tried it with the beta and the svn trunk as well. I run PHP 5.2.3-1ubuntu6.3 (cli). The command I use is: $ cake process DpkgQuery firefox My code is: <?php Class DpkgQueryTask extends Shell { var $uses = array('Package'); function execute($package=null) { if(!empty($package)) { $this->args[0] = $package; } while(empty($this->args[0])) { $this->args[0] = $this->in('Plese give a package name'); } $id = $id = $this->Package->field('id', array('Package.name'=>$this->args[0])); if(!$id) { $command = "dpkg-query -W -f='\${Package}\\t\${Section}\\n' " . $this->args[0]; $section = exec($command); $this->out($command); $this->Package->create(array('Package'=>array('name'=>$this->args[0], 'section'=>$section))); $id = $this->Package->lastInsertId(); $this->out('New package recognised: ' . $this->args[0] . ' (' . $id . ') belongs to ' . $section); } $this->out($id); // return $id; } } ?> Should I report it as a bug or should I rewrite something in my code? Thanks, V --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com 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 -~----------~----~----~----~------~----~------~--~---