Documentation
    Preparing search index...

    Class SQLiteBaseIntegerBuilder<T, TRuntimeConfig>Abstract

    Type Parameters

    • T extends ColumnBuilderBaseConfig<ColumnDataType, string>
    • TRuntimeConfig extends object = object

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    _: {
        brand: "ColumnBuilder";
        columnType: T["columnType"];
        data: T["data"];
        dataType: T["dataType"];
        dialect: "sqlite";
        driverParam: T["driverParam"];
        enumValues: T["enumValues"];
        generated: T extends { generated: G }
            ? G extends undefined ? unknown : G
            : unknown;
        hasDefault: T extends { hasDefault: U } ? U : boolean;
        identity: T extends { identity: U } ? U : unknown;
        name: T["name"];
        notNull: T extends { notNull: U } ? U : boolean;
    }
    $default: (
        fn: () => SQL<unknown> | T["data"],
    ) => HasRuntimeDefault<
        HasDefault<SQLiteBaseIntegerBuilder<T, TRuntimeConfig>>,
    >

    Alias for $defaultFn.

    $onUpdate: (
        fn: () => SQL<unknown> | T["data"],
    ) => HasDefault<SQLiteBaseIntegerBuilder<T, TRuntimeConfig>>

    Alias for $onUpdateFn.

    config: ColumnBuilderRuntimeConfig<
        T["data"],
        TRuntimeConfig & { autoIncrement: boolean },
    >
    "[entityKind]": string

    Methods

    • Adds a dynamic update value to the column. The function will be called when the row is updated, and the returned value will be used as the column value if none is provided. If no default (or $defaultFn) value is provided, the function will be called when the row is inserted as well, and the returned value will be used as the column value.

      Note: This value does not affect the drizzle-kit behavior, it is only used at runtime in drizzle-orm.

      Parameters

      • fn: () => SQL<unknown> | T["data"]

      Returns HasDefault<SQLiteBaseIntegerBuilder<T, TRuntimeConfig>>