"Rhino" <[EMAIL PROTECTED]> wrote:
> I'm new to MySQL but I have extensive experience with DB2 so I'm getting 
> quite confused about how MySQL is supposed to work.
>  
> I am using MySQL 4.0.11 on a Linux server running RedHat 9.2. I am 
> trying to create a pair of InnoDB tables that are related to one another 
> via a foreign key. I created the tables successfully but when I try to 
> insert a row into the child table that violates the foreign key,  MySQL 
> loads the bad row, even though the foreign key doesn't exist!
>  

[skip]

>  
> I got a very big clue when I ran this command:
> show table status from Sample;
>  
> It showed that my two tables were type "MyISAM", *not* "InnoDB".
> If my 
> tables really are "MyISAM", then I'm not surprised that the foreign key 
> constraint doesn't work since MyISAM doesn't support foreign keys, at 
> least as I understand the manual.
>  
> However, this doesn't answer the big question: *Why* aren't my tables 
> InnoDB since I explicitly defined them that way??
>  
> Can any MySQL veterans clear up this mystery for me?

If you try to create table type that is disabled or not compiled-in, MySQL creates 
MyISAM table type.
Execute statement
        SHOW VARIABLES LIKE "have_innodb";

If you see 'DISABLED' in the output, it means that you run MySQL server with 
skip-innodb option.
If you see 'NO' in the output, it means that MySQL server was configured without 
InnoDB support.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
       <___/   www.mysql.com




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to