10 lines
257 B
MySQL
10 lines
257 B
MySQL
|
|
-- name: InsertUser :one
|
||
|
|
INSERT INTO users (email, password_hash)
|
||
|
|
VALUES ($1, $2)
|
||
|
|
RETURNING id, email, password_hash, created_at, updated_at;
|
||
|
|
|
||
|
|
-- name: GetUserByEmail :one
|
||
|
|
SELECT id, email, password_hash, created_at, updated_at
|
||
|
|
FROM users
|
||
|
|
WHERE email = $1;
|