It just means that your models are not properly named or not properly placed. Some people save models with not strictly lower-cased filenames, some people just misspell filenames or varibales, etc and etc.
On Sep 15, 3:58 am, Herberth Amaral <[email protected]> wrote: > Sorry for post in this old topic, but I am having the same problem in > my models and their files are properly named. Also, the validation > rules, primary key and relationships that I am setting on these > models can't work. I spent almost an hour searching google a way to > resolve this problem, but I couldn't find anything. It's weird because > the problem doesn't occurs when I set those values in my controller. > Does anyone figure out what is going on? > > I am using php v5.2.9 and CakePHP v1.2.5 > > [Sorry for eventual english mistakes...It's not my native language :] > > On 5 set, 11:41, brian <[email protected]> wrote: > > > > > This can happen when Cake cannot locate the file for your model. Check > > that the file isnamed correctly: for MyModel the filename should be > > my_model.php. > > > On Fri, Sep 4, 2009 at 11:27 PM, learning_cake_php<[email protected]> > > wrote: > > > > well i dont know why cake behaves like this.. > > > i had model: > > > > class MyModel extends AppModel{ > > > ..................... > > > ..................... > > > //then i had a method > > > function myMethod(){ > > > ......................... > > > ......................... > > > } > > > > } > > > > when trying to call that method in my controller: > > > > class MyModelController extends AppController{ > > > ............................ > > > ............................ > > > > $this->MyModel->myMethod(); > > > > } > > > > cake is trying to execute it as an sql function thats why i got this > > > error invalid sql something.. > > > $this->MyModel->myMethod() is just a method used to pass data from my > > > controller to the model. > > > i had the same method on my other 2 models and it works fine only in > > > my third model cake interprets it as an sql function... > > > please help guys... --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
