Get rid of silos

This commit is contained in:
Abhishek Shroff
2024-08-05 23:33:43 +05:30
parent ecec4a95cf
commit c610dd6251
24 changed files with 247 additions and 579 deletions

View File

@@ -1,21 +0,0 @@
-- name: SiloById :one
SELECT * from silos where id = $1;
-- name: SiloByName :one
SELECT * from silos where name = $1;
-- name: DeleteSilo :exec
DELETE from silos where id = $1;
-- name: CreateSilo :exec
INSERT INTO silos(
id, created, modified, owner, name, storage
) VALUES(
$1, NOW(), NOW(), $2, $3, $4
);
-- name: ListAllSilos :many
SELECT * from silos;
-- name: ListSilosForUser :many
SELECT * from silos where owner = @user_id::int;