Re: Newbie question about keys
>Should I be using InnoDB tables, is there a way to switch storage type
>at the command line, because my phpmyadmin, shows that the InnoDB is
>loaded but not a valid choice for choosing as a storage engine type.
ALTER TABLE foo ENGINE=InnoDB;
ought to do it, assuming InnoDB is enabled. (This syntax works on
MySQL 5.0. Some earlier versions may have wanted Type=InnoDB instead
of ENGINE=InnoDB). It is possible it's compiled in but turned off
in my.cnf, and that may be why phpmyadmin doesn't offer it.
>Can anyone recomend what type of storage engine to use. Everything I
>have read says to use referential integrity and I am trying to keep
>this enforced. Is this not that important?
It depends on the application. Some applications don't use references
(like ones using a single table). Some use references but it's OK
if the record being referenced doesn't show up immediately and it's
not acceptable to have to manually sort the paperwork before entering
it. In some it's VERY important.
InnoDB does referential integrity and transactions, but it costs
you in speed. If you need referential integrity and/or transactions,
it's probably what you want to use.
Gordon L. Burditt
|