these are not in Normal Form quite yet.
you need to add Foreign keys that reference the Primary keys of the tables they are linked to.
I don't usually do a whole lot with building the actual tables but I know that you are missing the foreign keys.
in this Table:
CREATE TABLE `shipping_type`
(
`type_of_shipping` VARCHAR(30) NOT NULL DEFAULT '',
`price` DOUBLE(6, 2) NOT NULL,
`aprox_delivery` INT(11) NOT NULL,
PRIMARY KEY (`type_of_shipping`)
)
engine=innodb
DEFAULT charset=latin1;
type_of_shipping
is not a good primary key here. you should have a generic Table ID that is auto incremented and unique. so that each record has a unique id on that table.
This Table also needs a Table ID Column.
CREATE TABLE `state_tax`
(
`state_name` VARCHAR(11) NOT NULL DEFAULT '',
`sales_tax_rate` DOUBLE(6, 2) NOT NULL,
PRIMARY KEY (`state_name`)
)
engine=innodb
DEFAULT charset=latin1;
even though state_name
will be unique and isn't doubled up when you create the table, you still need a table id for a table like this. if the table ever grows there is the possibility for duplicates in that column. it's not good practice to write those two tables the way that you have them
The Password Column in your Customers Table needs to be encrypted This Blog Post looks like it talks about hashing and storing the password.