Created
October 1, 2015 08:27
-
-
Save sadaf2605/e15c3b9ef045c671a65f to your computer and use it in GitHub Desktop.
table items_item has no column named category_id
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # $ python manage.py sqlall items | |
| BEGIN; | |
| CREATE TABLE "items_category" ( | |
| "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, | |
| "name" varchar(200) NOT NULL | |
| ) | |
| ; | |
| CREATE TABLE "items_item" ( | |
| "id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, | |
| "name" varchar(200) NOT NULL, | |
| "description" text, | |
| "image" varchar(100) NOT NULL, | |
| "category_id" integer NOT NULL REFERENCES "items_category" ("id"), | |
| "show_in_front_page" bool NOT NULL, | |
| "always_show_in_front_page" bool NOT NULL, | |
| "is_trending" bool NOT NULL | |
| ) | |
| ; | |
| CREATE INDEX "items_item_6f33f001" ON "items_item" ("category_id"); | |
| COMMIT; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment