Module

x/justaos_orm/src/query/Query.ts>default

JUSTAOS's ORM (Object–relational mapping) tool is built for Deno and provides transparent persistence for JavaScript objects to Postgres database.
Latest
class default
import { default } from "https://dotland.deno.dev/x/justaos_orm@v10.0.0/src/query/Query.ts";

Methods

alter(nameWithSchema: string): Query
andWhere(
columnOrCompoundFunction:
| string
| number
| boolean
| ((where: WhereClause) => void)
,
operatorOrValue?: TWhereClauseOperator | any,
value?: any,
): Query

This method is used to set the AND where clause. (same as where)

columns(...args: any[]): Query
create(nameWithSchema: string): Query
cursor(): Promise<{ cursor: any; reserve: DatabaseClient; }>
delete(): Query
execute(sqlString?: string): Promise<any>
from(name: string): Query
getInstance(): Query
getSQLQuery(): string
getType(): string | undefined
groupBy(columnName: string): Query
inherits(nameWithSchema: string | undefined): Query
insert(): Query
into(nameWithSchema: string): Query
limit(limit: number): Query
offset(offset: number): Query
orderBy(columnNameOrOrderList?: string | TOrderBy[], direction?: TOrderByDirection): Query
orWhere(
columnOrCompoundFunction:
| string
| number
| boolean
| ((where: WhereClause) => void)
,
operatorOrValue?: TWhereClauseOperator | any,
value?: any,
): Query

This method is used to set the or where clause for the query.

returning(...args: any[]): Query
select(columnNameOrObjectOrArray?: string | string[] | { [key: string]: boolean; }, ...otherColumns: string[]): Query

This method is used to set the columns for the select query.

set(columnOrRecord: string | { [key: string]: any; }, value?: any): Query
setQuery(query: QueryType)
update(): Query
values(rows: any[]): Query
where(
columnOrCompoundFunction:
| string
| number
| boolean
| ((where: WhereClause) => void)
,
operatorOrValue?: TWhereClauseOperator | any,
value?: any,
): Query

This method is used to set the where clause for the query.