Christoph,

The only thing I see different in the tables, is the definition of the
id field.
`id` int(10) unsigned NOT NULL auto_increment
vs.
`id` int(10) NOT NULL auto_increment

I'd change them to match just for consistency sake.  And don't forget
to make the foreign keys match.  Come up with a standard for your db
and stick with it :)

Are you sure the tables are being generated?  I usually put a delete
table rule before every create table, just to be sure it doesn't halt
because the table already exists.

Also, maybe this isn't true any more, but it used to be suggested to
put your varchar fields last in your MyISAM tables, it would affect
storage space and speed.  But that might be a non-issue for you.

Hope any of this helps :)

- Tom

On Jan 24, 5:47 am, "Preloader" <[EMAIL PROTECTED]> wrote:
> The problem doesn't have anything to do with bake. When I call the
> products controller I get also the message: missing database table ...
> no database table for model Product ...
>
> Hmmm .... ?
>
> On 24 Jan., 11:21, "Preloader" <[EMAIL PROTECTED]> wrote:
>
> > Hello bakers,
>
> > I have a problem with bake: I have three database tables (users,
> > products and dealers) and i'd like to bake the corresponding models.
> > But in the list of possible models only the User-model is shown. Ok, I
> > could write the models by hand, of course no problem, but I think it
> > should also work out with bake.
>
> > Here the CREATE-Statement for the tables:
>
> > CREATE TABLE  `ibmtutdb`.`users` (
> >   `id` int(10) NOT NULL auto_increment,
> >   `username` varchar(40) NOT NULL,
> >   `password` varchar(40) NOT NULL,
> >   `email` varchar(255) NOT NULL,
> >   `firstname` varchar(40) NOT NULL,
> >   `lastname` varchar(40) NOT NULL,
> >   `last_login` datetime,
> >   `created` datetime,
> >   `modified` datetime,
> >   PRIMARY KEY  (`id`),
> >   UNIQUE KEY `username` (`username`),
> >   UNIQUE KEY `email` (`email`)
> > ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
>
> > CREATE TABLE  `ibmtutdb`.`products` (
> >   `id` int(10) unsigned NOT NULL auto_increment,
> >   `title` varchar(255) NOT NULL,
> >   `dealer_id` int(10) unsigned NOT NULL,
> >   `description` text NOT NULL,
> >   `created` datetime,
> >   `modified` datetime,
> >   PRIMARY KEY  (`id`)
> > ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
>
> > CREATE TABLE  `ibmtutdb`.`dealers` (
> >   `id` int(10) unsigned NOT NULL auto_increment,
> >   `title` varchar(255) NOT NULL,
> >   `created` datetime,
> >   `modified` datetime,
> >   PRIMARY KEY  (`id`)
> > ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
> 
> > Has anyone of you a hint for me?
> 
> > Thank you, Christoph :-)


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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