Re: Can not add foreign key constraint

2017-04-28 Thread David Mehler
ferenced field, so you'll need to add one on user, as was specified in the > create table you originally posted. > > On 28 April 2017 01:21:39 CEST, David Mehler <dave.meh...@gmail.com> wrote: >>Hello, >> >> Here's the output of the command show create tab

Re: Can not add foreign key constraint

2017-04-27 Thread David Mehler
er). >> >> >> - Original Message - >>> From: "David Mehler" <dave.meh...@gmail.com> >>> To: "MySql" <mysql@lists.mysql.com> >>> Sent: Tuesday, 25 April, 2017 23:07:19 >>> Subject: Re: Can not add foreign key cons

Re: Can not add foreign key constraint

2017-04-25 Thread David Mehler
Hello, Tried recreating the virtual_users table didn't solve anything. Would it be possible for anyone to check out my box directly? Thanks. Dave. On 4/24/17, Peter Brawley <peter.braw...@earthlink.net> wrote: > On 4/24/2017 20:47, David Mehler wrote: >> Hello, >> >>

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
CURRENT_TIMESTAMP, PRIMARY KEY (`user`), FOREIGN KEY (`user`) REFERENCES virtual_users(`user`) ON DELETE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8; Thanks. Dave. On 4/24/17, Peter Brawley <peter.braw...@earthlink.net> wrote: > On 4/24/2017 18:16, David Mehler wrote: >> Hello, >> >&g

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
Hello, I'm running Mysql 5.7.18. My virtual_users are working fine, it's the new table that isn't. Or am I missing something? Thanks. Dave. On 4/24/17, Peter Brawley <peter.braw...@earthlink.net> wrote: > On 4/24/2017 17:41, David Mehler wrote: >> Hello, >> >>

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
texts. > > Ah, an error cascade, as Shawn Green noticed, there's a typo in my > suggested command, should be ... > > show engine innodb status; > > PB > > - > >> >> PB >> >> - >> >>> >>> >>>

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
/17, Peter Brawley <peter.braw...@earthlink.net> wrote: > On 4/24/2017 13:59, David Mehler wrote: >> Hello, >> >> root@localhost [mail]> show engine innodb_status; >> ERROR 1286 (42000): Unknown storage engine 'innodb_status' > > Well it's very unlikely InnoDB

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
Hello, root@localhost [mail]> show engine innodb_status; ERROR 1286 (42000): Unknown storage engine 'innodb_status' This is on a Mysql 5.7 setup. Thanks. Dave. On 4/24/17, Peter Brawley <peter.braw...@earthlink.net> wrote: > On 4/24/2017 12:28, David Mehler wrote: >> Hell

Re: Can not add foreign key constraint

2017-04-24 Thread David Mehler
Hello, Here's the create table sand error message. root@localhost [(none)]> use mail; Database changed root@localhost [mail]> CREATE TABLE IF NOT EXISTS `lastauth` ( -> `user` varchar(40) NOT NULL, -> `remote_ip` varchar(18) NOT NULL, -> `timestamp` timestamp NOT NULL

Can not add foreign key constraints

2017-04-24 Thread David Mehler
Hello, I'm trying to add a table to an existing database. I'm wanting it to get one of it's fields from an already existing table. I've done this before in this database. This works: CREATE TABLE `virtual_users` ( `id` int(11) NOT NULL auto_increment, `domain_id` int(11) NOT NULL,