HELP: "IntegrityError: datatype mismatch" on Guided project: Creating Designing a Database

Hello on Guided project: Creating Designing a Database, Screen 5: Creating Tables without Foreign Key Relations I get this error when I insert park_codes into park:

IntegrityErrorTraceback (most recent call last)
<ipython-input-22-cf7222415ac6> in <module>()
     28 
     29 run_command(c1)
---> 30 run_command(c2)
     31 run_query(q)

    <ipython-input-11-20bc25a3bd08> in run_command(c)
     12         conn.execute('PRAGMA foreign_keys = ON;')
     13         conn.isolation_level = None
---> 14         conn.execute(c)
     15 
     16 def show_tables():

    IntegrityError: datatype mismatch

This is my insert code:

c1 = """
CREATE TABLE IF NOT EXISTS park (
    park_id TEXT PRIMARY KEY,
    name TEXT,
    nickname TEXT,
    city TEXT,
    state TEXT,
    notes TEXT
);
"""

c2 = """
INSERT OR IGNORE INTO "park"
SELECT
    park_id,
    name,
    aka,
    city,
    state,
    notes
FROM park_codes;
"""

q = """
SELECT * FROM park
LIMIT 5;
"""

run_command(c1)
run_command(c2)
run_query(q)

My previous code to create and insert a table for players had no issues and I’m even following solution code and still running into issues.

I am having the same issue. Did you ever figure out why the error was coming up?

@yaguneetsidhu @iamkcampbell Can you please share your notebooks and database files?

This kind of issue is tricky to triage because it very much depends on what you did to the database prior to getting to this point.

I just ran the solution in the app and it ran fine.