Re: innofb foreign keys problem

2003-01-14 Thread Natale Babbo
CIMEN [EMAIL PROTECTED] ha scritto: There are no other way you have to create the index first - Original Message - From: Natale Babbo [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, January 14, 2003 5:41 PM Subject: innofb foreign keys problem # - 3rd post

Foreign keys

2003-01-14 Thread Octavian Rasnita
HI all, I've read the following text in a book: ANSI SQL supports a special kind of key called a foreign key. Foreign keys help protect database integrity by enabling the database to manage things such as the deletion of rows with dependent relationships in other tables. Though MySQL supports

Re: Foreign keys

2003-01-14 Thread Zak Greant
On Tue, Jan 14, 2003 at 12:20:06PM +0200, Octavian Rasnita wrote: I've read the following text in a book: ANSI SQL supports a special kind of key called a foreign key. Foreign keys help protect database integrity by enabling the database to manage things such as the deletion of rows

Re: Foreign keys

2003-01-14 Thread Chris Boget
Use table type =Innodb for foreing keys and transacionts...etc and type =myisam for speed Yes, but do the foreign keys in InnoDB honor the constraints? I think that was the original question. What's the poing of using foreign keys if it's not going to maintain the integrity of your data

RE: Foreign keys

2003-01-14 Thread Adolfo Bello
Does MySQL allow using foreign keys or not? It does. Try it by yourself with version 4.0.8 +. Adolfo - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com

RE: innofb foreign keys problem

2003-01-14 Thread Ross Davis - DataAnywhere.net
To: Okan CIMEN; [EMAIL PROTECTED] Subject: Re: innofb foreign keys problem many thanks for your reply. then i ask me: why mysql needs explicit creation instead of create itself what it needs? manually creating the index seems to be a big complication (for big databases) and a waste of time. don't you

Re: innofb foreign keys problem

2003-01-14 Thread Adolfo Bello
then i ask me: why mysql needs explicit creation instead of create itself what it needs? manually creating the index seems to be a big complication (for big databases) and a waste of time. don't you think so? it's a bug or a wanted feature? why? I agree with you 100%. A foreign key,as its

Re: innofb foreign keys problem

2003-01-14 Thread greg55
yes -- you need to create indexes on foreign key colums. it would be better if one of the following 2 things happened instead. 1. foreign key creation failed if no index existed. 2. indexes were created automatically it's more dangerous than actually not having foreign keys as it stands since

mysql / innodb foreign keys

2003-01-13 Thread Natale Babbo
# - PLEASE HELP -- # hi to all, is it still true that mysql/innodb needs explicit index creation on foreign keys? why can't i use a standard syntax for foreign keys creations? i have a database schema (ddl) with over 50 tables and i was trying to create the database on mysql when

Re: cannot get foreign keys to work

2003-01-11 Thread Paul DuBois
At 18:45 +1100 1/10/03, Ben Mooney wrote: i have been using the following sql to try and get foreign keys working, the table creation works fine but when i try and delete data from the parent table it deletes as would normally happen in mysql, also the desired results do not happen if i use

cannot get foreign keys to work

2003-01-10 Thread Ben Mooney
i have been using the following sql to try and get foreign keys working, the table creation works fine but when i try and delete data from the parent table it deletes as would normally happen in mysql, also the desired results do not happen if i use RESTRICT. is this a problem to do

Re: Bug in foreign keys

2003-01-10 Thread Rafal Jank
MySQL = 4.0.1 but 4.0.5. I had these kind of problems with ALTER TABLE with 4.0.1 and 4.0.4, but not with 4.0.7 anymore (hey, this rhymes :). I guess it has nothing to do with the foreign keys, but with the temporary form table MySQL creates when you do an ALTER TABLE. Anyway, the problem

Re: Bug in foreign keys

2003-01-10 Thread Rafal Jank
- Original Message - From: Heikki Tuuri [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 09, 2003 11:04 PM Subject: Re: Bug in foreign keys Rafal, - Original Message - From: Rafal Jank [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Thursday

Re: cannot get foreign keys to work

2003-01-10 Thread Alan Hodgkinson
Dear Ben, i have been using the following sql to try and get foreign keys working, the table creation works fine but when i try and delete data from the parent table it deletes as would normally happen in mysql, also the desired results do not happen if i use RESTRICT. is this a problem

Re: Bug in foreign keys

2003-01-10 Thread Heikki Tuuri
MySQL-Max from http://www.mysql.com sql query . Subject: Re: Bug in foreign keys From: Rafal Jank Date: Fri, 10 Jan 2003 11:10:35 +0100 On Thu, 09 Jan 2003 23:41:46 +0200 Heikki Tuuri

Re: Bug in foreign keys

2003-01-10 Thread Rafal Jank
for MySQL See http://www.innodb.com, download MySQL-Max from http://www.mysql.com sql query . Subject: Re: Bug in foreign keys From: Rafal Jank Date: Fri, 10 Jan 2003 11:10:35 +0100

Bug in foreign keys

2003-01-09 Thread Rafal Jank
Hi! I have two tables: CREATE TABLE `pokoje` ( `nrpok_p` char(10) NOT NULL default '', `nip_h` int(10) NOT NULL default '0', `lozka_p` char(2) default NULL, `tv_p` char(1) default NULL, `lazienka_p` char(1) default NULL, `cena_p` int(10) default NULL, `zaliczka_p` int(10) default

Re: Bug in foreign keys

2003-01-09 Thread Paul DuBois
At 16:11 +0100 1/9/03, Rafal Jank wrote: Hi! I have two tables: CREATE TABLE `pokoje` ( `nrpok_p` char(10) NOT NULL default '', `nip_h` int(10) NOT NULL default '0', `lozka_p` char(2) default NULL, `tv_p` char(1) default NULL, `lazienka_p` char(1) default NULL, `cena_p` int(10)

Re: Bug in foreign keys

2003-01-09 Thread Rafal Jank
At 16:11 +0100 1/9/03, Rafal Jank wrote: Hi! I have two tables: CREATE TABLE `pokoje` ( `nrpok_p` char(10) NOT NULL default '', `nip_h` int(10) NOT NULL default '0', `lozka_p` char(2) default NULL, `tv_p` char(1) default NULL, `lazienka_p` char(1) default NULL,

Re: Bug in foreign keys

2003-01-09 Thread Heikki Tuuri
Rafal, - Original Message - From: Rafal Jank [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Thursday, January 09, 2003 6:18 PM Subject: Bug in foreign keys Hi! I have two tables: CREATE TABLE `pokoje` ( `nrpok_p` char(10) NOT NULL default '', `nip_h` int(10

Re: Bug in foreign keys

2003-01-09 Thread Heikki Tuuri
affected (0.01 sec) Records: 0 Duplicates: 0 Warnings: 0 - Original Message - From: Heikki Tuuri [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 09, 2003 11:04 PM Subject: Re: Bug in foreign keys Rafal, - Original Message - From: Rafal Jank [EMAIL PROTECTED

Re: Enforcement of foreign keys

2002-11-30 Thread Heikki Tuuri
Paul, - Original Message - From: Paul Vincent Craven [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Saturday, November 30, 2002 6:32 AM Subject: Enforcement of foreign keys Shouldn't the following be illegal? drop database registry; create database registry; use

Re: Debugging foreign keys in InnoDB

2002-11-23 Thread Heikki Tuuri
Michael, - Original Message - From: Michael Imari [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Saturday, November 23, 2002 11:17 AM Subject: Debugging foreign keys in InnoDB Hallo, is it possible to get some infos about what foreign key relation failed when this error

RE: Foreign Keys and InnoDb in MySQL

2002-11-15 Thread J. Ceferino Ortega
) on delete cascade. José Ceferino Ortega -Mensaje original- De: Bruce Lee [mailto:itnobita;hotmail.com] Enviado el: viernes, 15 de noviembre de 2002 4:35 Para: [EMAIL PROTECTED] Asunto: Foreign Keys and InnoDb in MySQL Hello, I have a problem about foreign key in using MySQL.com manual

re: Foreign Keys and InnoDb in MySQL

2002-11-15 Thread Egor Egorov
foreign keys, I have the following errors. BL Case 1: BL mysql create table customerTb ( BL customerId int not null, BL primary key (customerId) BL ) type = innodb; BL mysql insert into customerTb values (1), (2), (3), (4), (5); BL mysql create table carTb ( BL carId int not null, BL primary key

Foreign Keys and InnoDb in MySQL

2002-11-14 Thread Bruce Lee
Hello, I have a problem about foreign key in using MySQL.com manual. According to the example in MySQL.com manual, one foreign key is ok. However, I have 3 tables (ie. 2 for parent tables and 1 for child table). When I use 2 or more foreign keys, I have the following errors. Case 1: mysql

re: Foreign keys in InnoDB tables

2002-10-22 Thread Victoria Reznichenko
Christos, Monday, October 21, 2002, 5:46:07 AM, you wrote: CS Hello I am a brand new user of MySql, and have some questions about CS using InnoDB tables. CS I noticed in the manual that you can only specify CS - ON DELETE SET NULL CS Or CS - ON DELETE CASCADE CS What is the default

Foreign keys in InnoDB tables

2002-10-21 Thread Christos Stigas
Hello I am a brand new user of MySql, and have some questions about using InnoDB tables. I noticed in the manual that you can only specify - ON DELETE SET NULL Or - ON DELETE CASCADE What is the default behaviour if nothing is specified? Also, does anyone know if there are any plans to

Foreign keys in InnoDB tables

2002-10-20 Thread Christos Stigas
Hello I am a brand new user of MySql, and have some questions about using InnoDB tables. I noticed in the manual that you can only specify - ON DELETE SET NULL Or - ON DELETE CASCADE What is the default behaviour if nothing is specified? Also, does anyone know if there are any plans to

Re: InnoDB 3.23.52, foreign keys and update/cascade problem

2002-09-23 Thread j.random.programmer
Hi all: I'm seeing a strange problem updating a field if that field is referenced as a FK in another table. Consider: CREATE TABLE A ( id INTEGER NOT NULL AUTO_INCREMENT, name VARCHAR(20), PRIMARY KEY (id) ); CREATE TABLE B ( id INTEGER

Re: InnoDB 3.23.52, foreign keys and update/cascade problem

2002-09-23 Thread Paul DuBois
At 12:10 -0700 9/23/02, j.random.programmer wrote: Hi all: I'm seeing a strange problem updating a field if that field is referenced as a FK in another table. Consider: CREATE TABLE A ( id INTEGER NOT NULL AUTO_INCREMENT, name VARCHAR(20), PRIMARY KEY

InnoDB 3.23.52, foreign keys and update/cascade problem

2002-09-21 Thread j.random.programmer
Hi all: I'm seeing a strange problem updating a field if that field is referenced as a FK in another table. Consider: CREATE TABLE A ( id INTEGER NOT NULL AUTO_INCREMENT, name VARCHAR(20), PRIMARY KEY (id) ); CREATE TABLE B ( id INTEGER

foreign keys

2002-09-04 Thread Ilyas Keser
Is it in Mysql 4 possible to use foreign keys? If yes, how can I create two tables with foreign keys and use them? Thanks ilyas - Before posting, please check: http://www.mysql.com/manual.php (the manual) http

Re: foreign keys

2002-09-04 Thread Victoria Reznichenko
Ilyas, Wednesday, September 04, 2002, 2:27:27 PM, you wrote: IK Is it in Mysql 4 possible to use foreign keys? Foreign key constarints are supported in InnoDB tables (3.23 and 4.0) IK If yes, how can I create two tables with foreign keys and use them? Take a look at: http://www.mysql.com

RE: Foreign keys vont delete on cascade

2002-08-09 Thread Alexandre Zglav
- De : Heikki Tuuri [mailto:[EMAIL PROTECTED]] Envoyé : jeudi, 8. août 2002 08:17 À : [EMAIL PROTECTED] Objet : Re: Foreign keys vont delete on cascade Alexandre, ON DELETE CASCADE only works starting from 3.23.50 and 4.0.2. The version numbers are misleading because for the InnoDB subsystem

RE: Foreign keys vont delete on cascade

2002-08-09 Thread Alexandre Zglav
. août 2002 19:53 À : Heikki Tuuri; [EMAIL PROTECTED] Objet : RE: Foreign keys vont delete on cascade OK thanks a lot for your help ! :) I just downloaded the latest version ( 4.0.2) and installed it . I hoped I could keep the settings of my ini file ( my.ini) but I got the following error when

Primary and Foreign Keys in MySQL

2002-07-24 Thread Aamer Rauf
Hello, I am working on MySQL database. I have come across a 'problem' but don't know how to get around that. The problem is the following: I have a table, say TABLE1, with primary key being called as table1_id. Now there are other tables, like TABLE1A, TABLE1B, TABLE1C etc.. where I want to

RE: Primary and Foreign Keys in MySQL

2002-07-24 Thread Jon Frisby
- From: Aamer Rauf [mailto:[EMAIL PROTECTED]] Sent: Wednesday, July 24, 2002 12:55 PM To: [EMAIL PROTECTED] Subject: Primary and Foreign Keys in MySQL Hello, I am working on MySQL database. I have come across a 'problem' but don't know how to get around that. The problem

Re: Deleting foreign keys with Innodb tables

2002-07-18 Thread Victoria Reznichenko
Archbold, Thursday, July 18, 2002, 12:18:09 AM, you wrote: A I'm having a problem dropping a foreign key constraint from an Innodb table. I am using MySQL 3.23.51 for Win32. Any help would be greatly appreciated A I have a simple set up like the one below: A CREATE TABLE mastertable A (

Re: Deleting foreign keys with Innodb tables

2002-07-18 Thread Philip Molter
On Thu, Jul 18, 2002 at 03:41:01PM +0300, Victoria Reznichenko wrote: : Archbold, : Thursday, July 18, 2002, 12:18:09 AM, you wrote: : : A I'm having a problem dropping a foreign key constraint from an Innodb table. I am :using MySQL 3.23.51 for Win32. Any help would be greatly appreciated

Re: Deleting foreign keys with Innodb tables

2002-07-18 Thread Heikki Tuuri
Philip, - Original Message - From: Philip Molter [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Thursday, July 18, 2002 6:23 PM Subject: Re: Deleting foreign keys with Innodb tables On Thu, Jul 18, 2002 at 03:41:01PM +0300, Victoria Reznichenko wrote: : Archbold

Deleting foreign keys with Innodb tables

2002-07-17 Thread Archbold, David W.
Hi, I'm having a problem dropping a foreign key constraint from an Innodb table. I am using MySQL 3.23.51 for Win32. Any help would be greatly appreciated I have a simple set up like the one below: CREATE TABLE mastertable ( masterkey INT NOT NULL PRIMARY KEY AUTO_INCREMENT )

Foreign keys in MySQL

2002-07-10 Thread Hanxue Lee
Hi, In the MySQL documentation, it is stated that foreign keys in SQL are not used to join tables, but are used mostly for checking referential integrity (foreign key constraints). Does it mean that constraints are not supported? I need to have Update and perhaps Delete Referential Integrity

Re: Foreign keys in MySQL

2002-07-10 Thread Roger Baklund
* Hanxue Lee In the MySQL documentation, it is stated that foreign keys in SQL are not used to join tables, but are used mostly for checking referential integrity (foreign key constraints). This could have been formulated in a better way, IMHO. I would even say the statement is wrong

Interesting problem with Alter table and foreign keys on 3.23.51

2002-06-18 Thread Carl McNamee
Below is an example of a problem I'm having when issuing an alter table command to create a foreign key in mysql version 3.23.51. I am running the max version and the tables exist in the innodb table space. Thoughts? Comments? Criticism? Carl McNamee Systems Administrator Billing Concepts

Re: Interesting problem with Alter table and foreign keys on 3.23.51

2002-06-18 Thread Victoria Reznichenko
Carl, Tuesday, June 18, 2002, 5:30:31 PM, you wrote: CM Below is an example of a problem I'm having when issuing an alter table CM command to create a foreign key in mysql version 3.23.51. I am running the CM max version and the tables exist in the innodb table space. CM Thoughts? Comments?

Foreign keys in query optimization

2002-06-10 Thread Kiss Dániel
I studied the MySQL and InnoDB manual, but I did not find anything about the internal usage of foreign keys. I mean that I would like to know if foreign keys are used for query optimizations or functions like that. Because I think foreign keys should be used not only for keeping the data

Re: Foreign keys in query optimization

2002-06-10 Thread harm de laat
Kiss Dániel wrote: I studied the MySQL and InnoDB manual, but I did not find anything about the internal usage of foreign keys. MySQL does not support foreign keys at the moment. This will be implemented in version 4.1. For more info see: http://www.mysql.com/products/mysql-4.0

Re: Foreign keys in query optimization

2002-06-10 Thread cal
If you create in index on your FK then it will be used to optimize the query. =C= * * Cal Evans * Techno-Mage * http://www.calevans.com * - Original Message - From: Kiss Dániel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, June 10, 2002 9:19 AM Subject: Foreign keys in query

RE: Foreign keys in query optimization

2002-06-10 Thread Weaver, Walt
InnoDB supports foreign keys. And, an index must be created on the foreign key; this would help from an optimization point of view. --Walt Weaver Bozeman, Montana -Original Message- From: harm de laat [mailto:[EMAIL PROTECTED]] Sent: Monday, June 10, 2002 8:43 AM To: Kiss Dániel Cc

Re: Foreign keys in query optimization

2002-06-10 Thread Victoria Reznichenko
Kiss, Monday, June 10, 2002, 5:19:17 PM, you wrote: KD I studied the MySQL and InnoDB manual, but I did not find anything about KD the internal usage of foreign keys. KD I mean that I would like to know if foreign keys are used for query KD optimizations or functions like that. KD Because I

foreign keys in MySQL-Max-4.0.1

2002-06-07 Thread victoria papazoi
Hi, I use MySQL-Max-4.0.1 and i am wantering if is true that the information about the foreign keys are stored at comment properties of table with maximum length 60 characters? I need to use innodb tables with many f.keys.What I have to do? Thank you

foreign keys in MySQL-Max-4.0.1

2002-06-07 Thread victoria papazoi
Hi, I use MySQL-Max-4.0.1 and i am wantering if the information about the foreign keys are stored at comment properties of table with maximum length 60 characters? I need to use innodb tables with many f.keys.What I have to do? Thank you

FW: foreign keys in MySQL-Max-4.0.1

2002-06-07 Thread victoria papazoi
-Original Message- From: victoria papazoi [mailto:[EMAIL PROTECTED]] Sent: Friday, June 07, 2002 11:58 AM To: [EMAIL PROTECTED] Subject: foreign keys in MySQL-Max-4.0.1 Hi, I use MySQL-Max-4.0.1 and i am wantering if the information about the foreign keys are stored at comment

Help - foreign keys in MySQL-Max-4.0.1

2002-06-07 Thread victoria papazoi
Hi, I use MySQL-Max-4.0.1 and i am wantering if the information about the foreign keys are stored at comment properties of table with maximum length 60 characters? I need to use innodb tables with many f.keys.What I have to do? Thank you

Are FOREIGN KEYs used?

2002-06-06 Thread Kiss Dániel
I studied the MySQL and InnoDB manual, but I did not find anything about the internal usage of foreign keys. I mean if I define a foreign key it is good for me, because the InnoDB engine does not let the database to get integrity errors. But I think the foreign key definitions could be used

Re: Re: Foreign Keys and NULL

2002-05-30 Thread Egor Egorov
) ON DELETE CASCADE) TYPE=INNODB; CK OI!!! I'm going to sound like a complete ass now (I know) But since CK when does MySQL support FOREIGN keys?? *gasp* MAN this is going to CK make my life S much easier *curses at phpMyAdmin for not having the CK option* Yes, MySQL has

INNODB / Foreign Keys / mysqldump

2002-05-30 Thread Terry Yapt
Hello all, I am testing MySql Max 4.0.1 alpha. I have configured innodb tablespace and created the two manual tables example. But when I try to do a mysqldump to re-create the tables on another DB or 'SHOW CREATE TABLE child', NO-FOREIGN key information is gathered on results. However 'SHOW

Foreign Keys and NULL

2002-05-29 Thread ashok
Hi, I am evaluating InnoDB's Foreign Keys and am stuck. Using the sample tables I want to add records in the Child table with a NULL parent_id (this being referenced to the Parent table) as follows: CREATE TABLE parent(id INT NOT NULL, PRIMARY KEY (id)) TYPE=INNODB; CREATE

Re: Foreign Keys and NULL

2002-05-29 Thread Chris Knipe
to sound like a complete ass now (I know) But since when does MySQL support FOREIGN keys?? *gasp* MAN this is going to make my life S much easier *curses at phpMyAdmin for not having the option* *lick* *bounce* *all happy now* *goes to redo all his DBs* Now, I like MySQL 10 times

Re: Foreign Keys and NULL

2002-05-29 Thread Gabriel
snip tables OI!!! I'm going to sound like a complete ass now (I know) But since when does MySQL support FOREIGN keys?? *gasp* MAN this is going to make my life S much easier *curses at phpMyAdmin for not having the option* Do remember that this is only valid for mysql

Foreign Keys with MySQL 3.23.49 and 3.23.50

2002-05-28 Thread Jostkleigrewe, Heiner
sql,query Hello, i've tried the foreign key-example out of the documentation(3.5.6 Using Foreign Keys) on W2K (3.23.49 + 3.23.50) and LINUX (3.23.49). The tables persons and shirts are created as innodb-tables. I could insert a shirt for a non-existing person. Also i could delete

Re: Foreign Keys with MySQL 3.23.49 and 3.23.50

2002-05-28 Thread René Moonen
Hi Nothing is wrong! The behaviour of your example is correct, because MySQL does not support the concept of foreign keys. See section 1.4.4.5 of the MySQL manual. In other words data integrity between two tables is not ensured by MySQL. Your application code must solve this. Regards Rene

Re: Foreign Keys with MySQL 3.23.49 and 3.23.50

2002-05-28 Thread Christopher Book
This example is in InnoDB though, which should support foreign key constraints. Chris Book In other words data integrity between two tables is not ensured by MySQL. Your application code must solve this. - Before posting,

AW: Foreign Keys with MySQL 3.23.49 and 3.23.50

2002-05-28 Thread Jostkleigrewe, Heiner
] Betreff: Re: Foreign Keys with MySQL 3.23.49 and 3.23.50 In article [EMAIL PROTECTED], Jostkleigrewe, Heiner [EMAIL PROTECTED] writes: sql,query Hello, i've tried the foreign key-example out of the documentation(3.5.6 Using Foreign Keys) on W2K (3.23.49 + 3.23.50) and LINUX

missing foreign keys

2002-04-20 Thread Robert Douglass
Hello, I'm trying to apply my limited SQL knowledge to my newly acquired MySql database and am running into the following problem: In the (very good) manual on the mysql website, this example is given CREATE TABLE persons ( id SMALLINT UNSIGNED NOT NULL AUTO_INCREMENT, name CHAR(60) NOT

Re: missing foreign keys

2002-04-20 Thread Paul DuBois
At 18:22 +0200 4/20/02, Robert Douglass wrote: Hello, I'm trying to apply my limited SQL knowledge to my newly acquired MySql database and am running into the following problem: In the (very good) manual on the mysql website, this example is given CREATE TABLE persons ( id SMALLINT UNSIGNED

Foreign keys

2002-04-18 Thread Marius Røstad
Hello! I have a problem: How can I find the FOREIGN KEY definitions for a table? I'm using MySQL 4.0.1 MAX, and I define the table as a InnoDB-table. Someone, pleace help me! Marius - Before posting, please check:

Re: Foreign keys

2002-04-18 Thread Heikki Tuuri
- From: Marius Røstad [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Sent: Thursday, April 18, 2002 11:44 AM Subject: Foreign keys Hello! I have a problem: How can I find the FOREIGN KEY definitions for a table? I'm using MySQL 4.0.1 MAX, and I define the table as a InnoDB-table

Re: Foreign keys

2002-04-18 Thread Victoria Reznichenko
Marius, Thursday, April 18, 2002, 11:43:38 AM, you wrote: MR I have a problem: How can I find the FOREIGN KEY definitions for a table? MR I'm using MySQL 4.0.1 MAX, and I define the table as a InnoDB-table. SHOW TABLE STATUS statement shows you foreign key constraints for a table, look at:

foreign keys

2002-04-08 Thread root
i tried to use the foreign key feature in mysql 4.0.1 using innodb tables . then i have tried the delete cascade feature but it didn't work . I don't know why ? have you any suggestions ? . - Before posting, please check:

Re: foreign keys

2002-04-08 Thread Victoria Reznichenko
root, Monday, April 08, 2002, 12:24:42 PM, you wrote: r i tried to use the foreign key feature in mysql 4.0.1 using innodb tables . r then i have tried the delete cascade feature but it didn't work . I don't r know why ? have you any suggestions ? . InnoDB does not yet support ON DELETE

Re: Inserting records with null foreign keys?

2002-03-21 Thread Heikki Tuuri
on InnoDB -Original Message- From: Rick Flower [EMAIL PROTECTED] To: MySQL Mailing List [EMAIL PROTECTED] Cc: Heikki Tuuri [EMAIL PROTECTED] Date: Wednesday, March 20, 2002 10:56 PM Subject: Inserting records with null foreign keys? Hi all.. I noticed that the current version of InnoDB

Inserting records with null foreign keys?

2002-03-20 Thread Rick Flower
Hi all.. I noticed that the current version of InnoDB that is part of MySQL 3.23.47 does not allow using null foreign keys when doing inserts.. Is this intentional or a bug? This is allowed by SQL Server as a minimum (a test is being done by a co-worker currently against Oracle 8i to see

FW: mysqldump and foreign keys (possible Bug ??)

2002-03-20 Thread Chetan Lavti
PROTECTED]] Sent: Wednesday, March 20, 2002 9:35 PM To: Chetan Lavti Subject: Re: mysqldump and foreign keys (possible Bug ??) No, not working, When I run the command SHOW TABLE STATUS FROM yourdatabasename LIKE 'T'; shown in the manual (7.5.4.2 Foreign Key Constraints) I will see the foreign key

mysqldump and foreign keys

2002-03-19 Thread taraben . a
Hi, I just installed the MySQL max 4.0.1 and created a database with two INNODB and FOREIGN KEY tables as described in the Docs. When I run the mysqldump -a -B -c test I don't get the foreign key information. Any hint? Adib.

RE: mysqldump and foreign keys

2002-03-19 Thread Chetan Lavti
the mysqldesc tablename (at mysql command prompt) it shows the foreign keys.. am i right..?? Actually, I also wanted to know !! I am telling u what i have done and seen. Please, u also try for the same and see if it works fine. please, tell me also regarding this... Thanks and regards, Chetan Lavti

Re: Foreign keys in mysqldump?

2002-03-13 Thread Heikki Tuuri
] Newsgroups: mailing.database.mysql Date: Tuesday, March 12, 2002 7:18 PM Subject: Re: Foreign keys in mysqldump? InnoDB Hot Backup-0.33 beta is now available for Windows NT/2000/XP and Linux. Any plans for Solaris by the May 2002 release date? From: Heikki Tuuri [EMAIL PROTECTED] The beta testing

Re: Foreign keys in mysqldump?

2002-03-12 Thread Heikki Tuuri
://www.innodb.com for the online manual and latest news on InnoDB -Original Message- From: Bob McLaughlin [EMAIL PROTECTED] To: MySQL Mailing List [EMAIL PROTECTED] Cc: Heikki Tuuri [EMAIL PROTECTED] Date: Monday, March 11, 2002 8:11 PM Subject: Foreign keys in mysqldump? When I do a mysqldump

Re: foreign keys for relation ships

2002-03-12 Thread Heikki Tuuri
to MySQL/InnoDB through support contracts See http://www.innodb.com for the online manual and latest news on InnoDB -Original Message- From: van den Heuvel, Frank [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Date: Tuesday, March 12, 2002 10:16 AM Subject: foreign keys for relation

RE: Foreign keys in mysqldump?

2002-03-12 Thread Bob McLaughlin
in production work? Thanks much, -Bob -Original Message- From: Heikki Tuuri [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 4:50 AM To: Bob McLaughlin; MySQL Mailing List Subject: Re: Foreign keys in mysqldump? Bob, I have now improved foreign key support so that version

Re: Foreign keys in mysqldump?

2002-03-12 Thread Heikki Tuuri
Bob, thank you! I believe 3.23.50 will be out in two weeks. It is a stable version. The changes in foreign keys were actually rather small. I hope they do not degrade .50 to the beta category. Best regards, Heikki Tuuri Innobase Oy --- Order technical MySQL/InnoDB support at https

Re: Foreign keys in mysqldump?

2002-03-12 Thread Philip Molter
On Tue, Mar 12, 2002 at 11:50:12AM +0200, Heikki Tuuri wrote: : Bob, : : I have now improved foreign key support so that version 3.23.50 does : : 1. show the FOREIGN KEY definitions when you call SHOW CREATE TABLE; this : should also show them in mysqldumps; : 2. preserve FOREIGN KEY

Re: Foreign keys in mysqldump?

2002-03-12 Thread Heikki Tuuri
Philip, -Original Message- From: Philip Molter [EMAIL PROTECTED] To: Heikki Tuuri [EMAIL PROTECTED] Cc: Bob McLaughlin [EMAIL PROTECTED]; MySQL Mailing List [EMAIL PROTECTED] Date: Tuesday, March 12, 2002 4:21 PM Subject: Re: Foreign keys in mysqldump? On Tue, Mar 12, 2002 at 11:50

Re: Foreign keys in mysqldump?

2002-03-12 Thread David Felio
InnoDB Hot Backup-0.33 beta is now available for Windows NT/2000/XP and Linux. Any plans for Solaris by the May 2002 release date? From: Heikki Tuuri [EMAIL PROTECTED] The beta testing of InnoDB Hot Backup (a non-free add-on tool) started on Monday. If you want to take part in the beta

Foreign keys in mysqldump?

2002-03-11 Thread Bob McLaughlin
When I do a mysqldump and include table creation, it does not seem to include the foreign key constraints in the create table statements of the InnoDB tables. Is there a command line switch or other way to make this happen? Thanks, -Bob

foreign keys for relation ships

2002-03-11 Thread van den Heuvel, Frank
Hello, I am creating tables within MySql 3.23.49. I want to add relation ships between different tables. I tried to do this with foreign key statements. For example: CREATE TABLE domains ( domain varchar(100) NOT NULL, registrarid int(10) NOT NULL, foreign key (registrarid) REFERENCES

Re: foreign keys in mysql

2002-03-06 Thread Arjen Lentz
Hi, On Thu, 2002-03-07 at 08:20, bin cai wrote: I am encountering one problem. I am using mysql as the dabase for my application. I create a table like takeexam as following:create table takelabexam( sid varchar(10) not null, cid varchar(20) not null,

Re: Innodb tables lose foreign keys after creating an index...

2002-03-03 Thread Heikki Tuuri
Hi! -Original Message- From: j.random.programmer [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Date: Saturday, March 02, 2002 5:21 AM Subject: Re: Innodb tables lose foreign keys after creating an index... --- Heikki Tuuri [EMAIL PROTECTED] wrote: Heikki: Is there a fix

Re: Innodb tables lose foreign keys after creating an index...

2002-03-01 Thread Heikki Tuuri
keys after creating an index... Hi all.. Are any of you aware of a way to get indexes to work at all with Innodb tables containing foreign keys? I'm finding that after doing a create index on a table which *had* foreign keys, after the create, the foreign keys are gone.. I've included a simple test

Re: Innodb tables lose foreign keys after creating an index...

2002-03-01 Thread j.random.programmer
--- Heikki Tuuri [EMAIL PROTECTED] wrote: Rick, sorry, it is not mentioned in the manual that MySQL performs a CREATE INDEX by doing an ALTER TABLE. And ALTER TABLE has the feature (= documented bug) that it removes foreign key definitions. Heikki: Is there a fix planned for the alter

Re: flexible foreign keys?

2002-02-28 Thread Jeff Kilbride
Well, honestly, by deleting the record in the parent, you're already defeating the purpose of the foreign key by corrupting the referential integrity of the parent to child relationship. The basic reasoning behind foreign keys is to maintain this integrity and prevent this type of corruption. So

Innodb tables lose foreign keys after creating an index...

2002-02-28 Thread Rick Flower
Hi all.. Are any of you aware of a way to get indexes to work at all with Innodb tables containing foreign keys? I'm finding that after doing a create index on a table which *had* foreign keys, after the create, the foreign keys are gone.. I've included a simple test below which shows off

Re: flexible foreign keys?

2002-02-27 Thread Jeff Kilbride
InnoDB doesn't support the CASCADE functionality of foreign keys, so it's possible deleting the key from the parent table won't have any effect on existing transactions in the child. It may only prevent new records from being inserted with that key -- which is essentially what you want. Most DBs

Re: flexible foreign keys?

2002-02-27 Thread David Felio
, Jeff Kilbride wrote: InnoDB doesn't support the CASCADE functionality of foreign keys, so it's possible deleting the key from the parent table won't have any effect on existing transactions in the child. It may only prevent new records from being inserted with that key -- which is essentially

Re: flexible foreign keys?

2002-02-27 Thread Jeff Kilbride
: flexible foreign keys? When I try to delete a row from the parent table and the key is in use in the child table, I get: ERROR 1217: Cannot delete a parent row: a foreign key constraint fails So it doesn't cascade and delete rows in the child table (assuming I am interpreting cascade

Alter Table with InnoDB table type having foreign keys

2002-02-23 Thread Bob McLaughlin
such as innodb_fail_alter_table_with_fk that would warn or fail the alter table statement if the table type was InnoDB and foreign keys were going to be dropped. If this latter option was implemented, it would prevent RI from being quietly lost. Thanks much, -Bob

foreign keys to what end?

2002-02-21 Thread David Felio
that describe the customer type, transaction type, etc. or have valid values for routing number, status, etc. Should all of these be set up as foreign keys, or should some of referential integrity be done programmatically? How do you draw the line between how many foreign keys are too many

RE: foreign keys to what end?

2002-02-21 Thread adam nelson
Using foreign keys is a really, really good idea. Programs can't be trusted (and what about running sql queries ad hoc). Even with a really big database I wouldn't get rid of the keys, just time to move to a bigger better machine/configuration. -Original Message- From: David Felio

Re: Re: Foreign keys in InnoDB tables

2002-02-16 Thread Heikki Tuuri
Martin, -Original Message- From: Martin Bratbo [EMAIL PROTECTED] Newsgroups: mailing.database.mysql Date: Saturday, February 16, 2002 4:46 PM Subject: Re: Re: Foreign keys in InnoDB tables Heikki here is the statements that i cant get to work: first I create one innoDB table: fk1

<    1   2   3   4   5   >