Hi Team,
I have a table in sqlite db.
I want to add a column which would be foreign key to a parent table.
I have a connector with:
mode = execute, request = CREATE TABLE IF NOT EXISTS project_assignee (id INTEGER PRIMARY KEY, person, role, status, project_id FOREIGN KEY REFERENCES project1 (id) )
But the execution is failing with below error:
{ “message”: “[SQLITE_ERROR] SQL error or missing database (near \”FOREIGN\”: syntax error)”, “success”: false }
Please suggest.
I found the solution as I had to modify the request as below removing the FOREIGN KEY key-word.
CREATE TABLE IF NOT EXISTS project_assignee (id INTEGER PRIMARY KEY, person, role, status, project_id INTEGER REFERENCES project1 (id) )
You must be logged in to reply to this topic.
Enter the destination URL
Or link to existing content