Skip to content

Instantly share code, notes, and snippets.

@muojp
Created August 15, 2012 12:28
Show Gist options
  • Save muojp/3359703 to your computer and use it in GitHub Desktop.
Save muojp/3359703 to your computer and use it in GitHub Desktop.
sqlite> CREATE TABLE t3(_id INTEGER PRIMARY KEY AUTOINCREMENT, col1 VARCHAR(255), col2 INTEGER);
sqlite> CREATE UNIQUE INDEX idx_uniq ON t3(_id, col1, col2);
sqlite> .schema t3
CREATE TABLE t3(_id INTEGER PRIMARY KEY AUTOINCREMENT, col1 VARCHAR(255), col2 INTEGER);
CREATE UNIQUE INDEX idx_uniq ON t3(_id, col1, col2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment