UNPKG

@adonisjs/lucid

Version:

SQL ORM built on top of Active Record pattern

23 lines (22 loc) 705 B
/// <reference path="../../../adonis-typings/index.d.ts" /> import { Knex } from 'knex'; import { RawBuilderContract } from '@ioc:Adonis/Lucid/Database'; /** * Exposes the API to construct raw queries. If you want to execute * raw queries, you can use the RawQueryBuilder */ export declare class RawBuilder implements RawBuilderContract { private sql; private bindings?; private wrapBefore; private wrapAfter; constructor(sql: string, bindings?: any); /** * Wrap the query with before/after strings. */ wrap(before: string, after: string): this; /** * Converts the raw query to knex raw query instance */ toKnex(client: Knex.Client): Knex.Raw; }