SurrealQL statements against the database
db.RawQuery[T](sql, vars)
db.Select[T,R](resource)
db.Live[T](table, diff)
db.LiveNotifications[T](queryUuid)
db.Kill(queryUuid)
Method | Description |
---|---|
db.Create[T](table, data) | Creates a record in the database |
db.Insert[T](table, data) | Inserts one or multiple records in the database |
db.InsertRelation[T](table, data) | Inserts one or multiple records in the database |
db.Update[T](table, data) | Updates all records in a table, or a specific record |
db.Upsert[T](table, data) | Creates or updates a specific record |
db.Merge[T](what, data) | Modifies all records in a table, or a specific record |
db.Patch[T](table, data) | Applies JSON Patch changes to all records in a table, or a specific record |
db.Delete(data) | Deletes all records, or a specific record |
Method | Description |
---|---|
db.SignUp(credentials) | Signs this connection up to a specific authentication scope |
db.SignIn(credentials) | Signs this connection in to a specific authentication scope |
db.Invalidate() | Invalidates the authentication for the current connection |
db.Authenticate(token) | Authenticates the current connection with a JWT token |
db.Info[T]() | Returns the record of an authenticated scope user |