UNPKG

@directus/api

Version:

Directus is a real-time API and App dashboard for managing SQL database content

25 lines (24 loc) 1.45 kB
import type { KNEX_TYPES } from '@directus/constants'; import type { Column } from '@directus/schema'; import type { Field, RawField, Relation, Type } from '@directus/types'; import type { Knex } from 'knex'; import type { CreateIndexOptions, Options, SortRecord, Sql } from '../types.js'; import { SchemaHelper } from '../types.js'; export declare class SchemaHelperOracle extends SchemaHelper { generateIndexName(type: 'unique' | 'foreign' | 'index', collection: string, fields: string | string[]): string; changeToType(table: string, column: string, type: (typeof KNEX_TYPES)[number], options?: Options): Promise<void>; castA2oPrimaryKey(): string; preRelationChange(relation: Partial<Relation>): void; processFieldType(field: Field): Type; getDatabaseSize(): Promise<number | null>; /** * Oracle throws an error when overwriting the nullable option for an existing column with the same value. */ setNullable(column: Knex.ColumnBuilder, field: RawField | Field, existing: Column | null): void; prepQueryParams(queryParams: Sql): Sql; prepBindings(bindings: Knex.Value[]): any; addInnerSortFieldsToGroupBy(groupByFields: (string | Knex.Raw)[], sortRecords: SortRecord[], _hasRelationalSort: boolean): void; getColumnNameMaxLength(): number; getTableNameMaxLength(): number; createIndex(collection: string, field: string, options?: CreateIndexOptions): Promise<Knex.SchemaBuilder>; }