Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- __________________________
- | id | email | password |
- |-------------------------|
- | 1 | a@g.com | 123 |
- | 2 | b@g.com | 123 |
- | 3 c@g.com | 123 |
- | 4 d@g.com | 123 |
- --------------------------
- ______________
- |id | name |
- |--------------|
- |1 | customer |
- |2 | retailer |
- ----------------
- __________________
- |id_user | id_role|
- |------------------|
- | 1 | 1 | -> a@gmail.com is a customer
- | 2 | 2 | -> b@gmail.com is a retailer
- | 3 | 1 | -> c@gmail.com is a customer
- | 4 | 1 | -> d@gmail.com is a customer
- ------------------
- ____________________
- |id| user_id| price |
- |--------------------|
- |1 | 1 | 10.00 | -> price claimed by a customer a@gmail.com
- |2 | 2 | 5.00 | -> price claimed by a retailer b@gmail.com
- |3 | 1 | 6.00 | -> price claimed by a previous customer a@gmail.com
- |4 | 3 | 5.00 | -> price claimed by a customer c@gmail.com
- |5 | 2 | 7.00 | -> price claimed by a previous retailer b@gmail.com // How to get this one
- |6 | 3 | 8.00 | -> price claim by a customer c@gmail.com
- ---------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement