"Invalid object name AspNetRoles" on first run
Fresh install on SQL Server, the app starts but throws "Invalid object name 'AspNetRoles'". Tables don't seem to exist. How do I provision the schema?
Fresh install on SQL Server, the app starts but throws "Invalid object name 'AspNetRoles'". Tables don't seem to exist. How do I provision the schema?
AutoMigrate defaults to false — you provision the DB yourself. Run database/okommerce-schema.sql against the SAME database your connection string points to. The error almost always means the app connected to a different/empty DB.
Double-check the Database name in ConnectionStrings:Default matches where you ran the script. I'd wasted an hour pointing at the wrong DB.
Anyone can read the community. Create a free account — verified & approved — to reply.
Thanks for subscribing. We'll send product updates and release notes — no noise, and you can unsubscribe anytime.