Skip to content

Commit fc321f1

Browse files
committed
fix for mysql create table
1 parent 1303440 commit fc321f1

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

go/samples/http/todos/queries.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,8 @@ func (sql PGQueries) TodoById() string {
4545
// MySQLQueries impl
4646
func (sql MySQLQueries) CreateTodosTableIfNotExists() string {
4747
return `CREATE TABLE IF NOT EXISTS todos(
48-
id INT NOT NULL AUTO_INCREMENT,
48+
id INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
4949
task VARCHAR(1000) NOT NULL
50-
51-
PRIMARY KEY(id)
5250
)`
5351
}
5452

0 commit comments

Comments
 (0)