I have a table namedpayment_requestin MySQL
DESCRIBE payment_requestprovides the following output,
Theorderbooktable is provided below,
I want to add theidin thepayment_requesttable inorderbookas theidcolumn (second position) with the name after Foreign key topayment_request_id.
What is the SQL used to run MySQL?
You can do this when creating the table:
Or by changing the form:
Also seethis tutorial.
First, you need to add a new column to the table
orderbookThen add a constraint that defines the foreign key
refer to: