CREATE TABLE IF NOT EXISTS sessions (
    session_id INTEGER PRIMARY KEY AUTOINCREMENT,
    user_id INTEGER UNIQUE NOT NULL
    session_token TEXT UNIQUE NOT NULL ,
    FOREIGN KEY (user_id) references users(user_id) ON DELETE CASCADE
);

INSERT INTO sessions (user_id, session_token) 
VALUES (@userID, @token);

SELECT session_id, user_id, session_token, 
FROM sessions
WHERE session_token = @token;

SELECT session_id, user_id, session_token, 
FROM sessions
WHERE session_id = @sessionID;


