Skip to main content
Sign in
Snippets Groups Projects
Select Git revision
  • a03243a826bb4eb5eebad19133f6b15e2f5dfdc2
  • ballinvoher default protected
  • client-http-server-for-token
  • master
  • gitlab-auth-issue
  • windows
  • microsoft
  • message
  • azure_auth
  • prometheus
  • permission-templates
  • no-datastore
  • save-public-keys
  • gitlab-group-level-start
  • v1.1.0
  • v1.0.0
  • v0.1
17 results

google.go

Blame
  • query.sql 1.43 KiB
    -- name: GetLocation :one
    SELECT * FROM locations
    WHERE id = ? LIMIT 1;
    
    -- name: CreateLocation :one
    INSERT INTO locations
    (id, description)
    VALUES (?, ?)
    RETURNING *;
    
    -- name: UpdateLocation :one
    UPDATE locations
    SET description = ?
    WHERE id = ?
    RETURNING *;
    
    -- name: DeleteLocation :one
    DELETE FROM locations
    WHERE id = ?
    RETURNING *;
    
    -- name: GetLocations :many
    SELECT * FROM locations;
    
    -- name: GetLocationsWithFilter :many
    SELECT * FROM locations
    WHERE description LIKE ?;
    
    -- name: GetBox :one
    SELECT * FROM boxes
    WHERE id = ? LIMIT 1;
    
    -- name: CreateBox :one
    INSERT INTO boxes
    (id, location, description)
    VALUES (?, ?, ?)
    RETURNING *;
    
    -- name: UpdateBox :one
    UPDATE boxes
    SET location = ?, description = ?
    WHERE id = ?
    RETURNING *;
    
    -- name: DeleteBox :one
    DELETE FROM boxes
    WHERE id = ?
    RETURNING *;
    
    -- name: GetBoxes :many
    SELECT * FROM boxes;
    
    -- name: GetBoxesWithFilter :many
    SELECT * FROM boxes
    WHERE description LIKE ?;
    
    -- name: GetContent :one
    SELECT * FROM contents
    WHERE id = ? LIMIT 1;
    
    -- name: CreateContent :one
    INSERT INTO contents
    (id, box, description, tags)
    VALUES (?, ?, ?, ?)
    RETURNING *;
    
    -- name: UpdateContent :one
    UPDATE contents
    SET box = ?, description = ?, tags = ?
    WHERE id = ?
    RETURNING *;
    
    -- name: DeleteContent :one
    DELETE FROM contents
    WHERE id = ?
    RETURNING *;
    
    -- name: GetContents :many
    SELECT * FROM contents;
    
    -- name: GetContentsWithFilter :many
    SELECT * FROM contents
    WHERE description LIKE ?;
    
    -- vim:et