Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 415
  • Last Modified:

How do I customize this query for PhpMyAdmin

ALTER TABLE 'tbl_issue' ADD CONSTRAINT 'FK_issue_project' FOREIGN KEY
('project_id') REFERENCES 'tbl_project' ('id') ON DELETE CASCADE ON
UPDATE RESTRICT;

I am getting an error.
0
rroslan
Asked:
rroslan
  • 2
1 Solution
 
mattibuttCommented:
what is the error message you are getting you have  follow the specific version of mysql if its an old version then obviously query wont work
0
 
cyberkiwiCommented:
ALTER TABLE tbl_issue ADD CONSTRAINT FK_issue_project FOREIGN KEY
(project_id) REFERENCES tbl_project (id) ON DELETE CASCADE ON
UPDATE RESTRICT;
0
 
cyberkiwiCommented:
Or use backquotes ` instead of the single quotes '
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now