TEXT   23
item
Guest on 16th March 2023 07:17:18 AM


  1. mysql> create table invoice_item(inv_id int,pid int,quantity int,foreign key(inv_id) references invoice_master(inv_id),foreign key(pid) references Product(pid));
  2. Query OK, 0 rows affected (0.24 sec)
  3.  
  4. mysql> desc invoice_item;
  5. +----------+---------+------+-----+---------+-------+
  6. | Field    | Type    | Null | Key | Default | Extra |
  7. +----------+---------+------+-----+---------+-------+
  8. | inv_id   | int(11) | YES  | MUL | NULL    |       |
  9. | pid      | int(11) | YES  | MUL | NULL    |       |
  10. | quantity | int(11) | YES  |     | NULL    |       |
  11. +----------+---------+------+-----+---------+-------+
  12. 3 rows in set (0.00 sec)

Raw Paste

Login or Register to edit or fork this paste. It's free.