| List: | General Discussion | « Previous MessageNext Message » | |
| From: | Michael Stassen | Date: | November 29 2004 3:33am |
| Subject: | Re: How to retrieve constraints and links from MySQL tables? | ||
| View as plain text | |||
Varakorn Ungvichian wrote: > --- Michael Stassen <Michael.Stassen@stripped> > wrote: > > >>Varakorn Ungvichian wrote: >> >>>Just realised something: my table was MyIsam. I >>>switched it to InnoDB (which support FKs), but >> >>now: >> >>>1. "Show Create Table" still doesn't show >> >>reference >> >>>links, and >> >>Well, of course not. It won't show them until you >>create them, which you >>haven't done according to #2. > > I'm thinking more along the terms of when I include > something like "position_id tinyint(4) NOT NULL > default 1 references positions (position_id)" in the > "create table" statement. Which is parsed but silently ignored for non-InnoDB tables <http://dev.mysql.com/doc/mysql/en/CREATE_TABLE.html>, so it won't be there in SHOW CREATE TABLE output. InnoDB tables support this, but you have to have the index(es) in place for it to work. See the manual for more <http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html>. > Varakorn Ungvichian Michael
| Thread | ||
|---|---|---|
| • How to retrieve constraints and links from MySQL tables? | Varakorn Ungvichian | 26 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Martijn Tonies | 26 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Varakorn Ungvichian | 28 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Varakorn Ungvichian | 28 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Martijn Tonies | 28 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Michael Stassen | 28 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Varakorn Ungvichian | 29 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Michael Stassen | 29 Nov |
| • RE: How to retrieve constraints and links from MySQL tables? | Mechain Marc | 26 Nov |
| • Re: How to retrieve constraints and links from MySQL tables? | Martijn Tonies | 26 Nov |
