Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-06 Thread Jon Bennett
> Ok, I've upgraded to 2.0.2, changed the code of > EpisodeReleaseController.php, and i have fixed the add problem. Now I > am building the edit function. I have used the console cake bake > controller to create it, but it seems that each time I press save it > adds a new association. > Example; >

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-05 Thread Mattia Manzati
Ok, I've upgraded to 2.0.2, changed the code of EpisodeReleaseController.php, and i have fixed the add problem. Now I am building the edit function. I have used the console cake bake controller to create it, but it seems that each time I press save it adds a new association. Example; "Post" as been

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Mattia Manzati
Ok, putted code on github. This is the repo: https://github.com/ilmattodel93/IMattiDel93-s-Site Thanks again for your help! ^^ On 2 Nov, 18:47, Thiago Belem wrote: > Put your code on Github or Gists and send us the link. > > Thiago Belem, enviado do meu Android > Em 02/11/2011 15:28, "Mattia Man

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Thiago Belem
Put your code on Github or Gists and send us the link. Thiago Belem, enviado do meu Android Em 02/11/2011 15:28, "Mattia Manzati" escreveu: > I Have already checked, and all table are already well related. Same > column type INT(11) and InnoDB powered. But I still have the > problem... :S > What

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Mattia Manzati
I Have already checked, and all table are already well related. Same column type INT(11) and InnoDB powered. But I still have the problem... :S What to do now? The code I am using works if I use cakephp1.3 On 2 Nov, 17:51, Jeremy Burns wrote: > Use InnoDB. As John says, it won't let you creat

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Jeremy Burns
Use InnoDB. As John says, it won't let you create RI between fields with different types (and it's very precise) and you get transactions thrwn in for good measure. On 2 Nov 2011, at 16:14, Jon Bennett wrote: >> I've had some similar trouble with 2.0 >> turned out the fields in the DB were not

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Jon Bennett
> I've had some similar trouble with 2.0 > turned out the fields in the DB were not the same type. > id on one table was a bigint and the foreign key on the relationship table > was a regular integer. > atenciosamente, With MySQL you can catch these errors at db schema level if you use foreign ke

Re: CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Werner Petry Moraes
I've had some similar trouble with 2.0 turned out the fields in the DB were not the same type. id on one table was a bigint and the foreign key on the relationship table was a regular integer. atenciosamente, Werner Petry Moraes werne...@gmail.com On Wed, Nov 2, 2011 at 07:52, Mattia Manzati w

CakePHP2.0.1 - Problem with saving HABTM

2011-11-02 Thread Mattia Manzati
Hi all! Thanks in advance for replys! :P I have the following model: class EpisodeRelease extends AppModel{ > public $cacheQueries = true; > public $name = 'EpisodeRelease'; > public $primaryKey = 'id'; > public $table = 'episode_releases'; > public $hasMany = array( >