Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

drizzle-orm-pg

Package Overview
Dependencies
Maintainers
3
Versions
170
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

drizzle-orm-pg - npm Package Compare versions

Comparing version 0.12.0-beta.10 to 0.12.0-beta.11

columns/bigSerial.d.ts

1

columns/index.d.ts

@@ -20,1 +20,2 @@ export * from './bigint';

export * from './varchar';
export * from './real';

@@ -38,2 +38,3 @@ "use strict";

__exportStar(require("./varchar"), exports);
__exportStar(require("./real"), exports);
//# sourceMappingURL=index.js.map

3

columns/interval.d.ts
import { ColumnData, ColumnDriverParam, ColumnHasDefault, ColumnNotNull, TableName } from 'drizzle-orm/branded-types';
import { AnyPgTable } from '../table';
import { PgColumnBuilder, PgColumnWithMapper } from './common';
import { PrecisionLimit } from './timestamp';
export declare class PgIntervalBuilder<TData extends ColumnData<string> = ColumnData<string>, TNotNull extends ColumnNotNull = ColumnNotNull<false>, THasDefault extends ColumnHasDefault = ColumnHasDefault<false>> extends PgColumnBuilder<ColumnData<TData>, ColumnDriverParam<string>, TNotNull, THasDefault> {

@@ -17,4 +18,4 @@ readonly config: IntervalConfig;

fields?: 'year' | 'month' | 'day' | 'hour' | 'minute' | 'second' | 'year to month' | 'day to hour' | 'day to minute' | 'day to second' | 'hour to minute' | 'hour to second' | 'minute to second';
precision?: number;
precision?: PrecisionLimit;
}
export declare function interval<T extends string = string>(name: string, config?: IntervalConfig): PgIntervalBuilder<ColumnData<T>, ColumnNotNull<false>, ColumnHasDefault<false>>;

@@ -14,2 +14,25 @@ import { ColumnData, ColumnDriverParam, ColumnHasDefault, ColumnNotNull, TableName } from 'drizzle-orm/branded-types';

}
export declare function numeric(name: string, precision?: number, scale?: number): PgNumericBuilder<ColumnNotNull<false>, ColumnHasDefault<false>>;
export declare function numeric(name: string, config: {
precision: number;
scale?: number;
}): PgNumericBuilder;
export declare function numeric(name: string, config: {
precision: number;
scale: number;
}): PgNumericBuilder;
export declare function numeric(name: string, config?: {
precision: number;
scale: number;
}): PgNumericBuilder;
export declare function decimal(name: string, config: {
precision: number;
scale?: number;
}): PgNumericBuilder;
export declare function decimal(name: string, config: {
precision: number;
scale: number;
}): PgNumericBuilder;
export declare function decimal(name: string, config?: {
precision: number;
scale: number;
}): PgNumericBuilder;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.numeric = exports.PgNumeric = exports.PgNumericBuilder = void 0;
exports.decimal = exports.numeric = exports.PgNumeric = exports.PgNumericBuilder = void 0;
const common_1 = require("./common");

@@ -36,6 +36,10 @@ class PgNumericBuilder extends common_1.PgColumnBuilder {

exports.PgNumeric = PgNumeric;
function numeric(name, precision, scale) {
return new PgNumericBuilder(name, precision, scale);
function numeric(name, config) {
return new PgNumericBuilder(name, config === null || config === void 0 ? void 0 : config.precision, config === null || config === void 0 ? void 0 : config.scale);
}
exports.numeric = numeric;
function decimal(name, config) {
return new PgNumericBuilder(name, config === null || config === void 0 ? void 0 : config.precision, config === null || config === void 0 ? void 0 : config.scale);
}
exports.decimal = decimal;
//# sourceMappingURL=numeric.js.map

@@ -5,2 +5,3 @@ import { ColumnData, ColumnDriverParam, ColumnHasDefault, ColumnNotNull, TableName } from 'drizzle-orm/branded-types';

import { PgDateColumnBaseBuilder } from './date.common';
import { PrecisionLimit } from './timestamp';
export declare class PgTimeBuilder<TData extends ColumnData<string> = ColumnData<string>, TNotNull extends ColumnNotNull = ColumnNotNull<false>, THasDefault extends ColumnHasDefault = ColumnHasDefault<false>> extends PgDateColumnBaseBuilder<ColumnData<TData>, ColumnDriverParam<string>, TNotNull, THasDefault> {

@@ -20,5 +21,5 @@ readonly withTimezone: boolean;

export interface TimeConfig {
precision?: number;
precision?: PrecisionLimit;
withTimezone?: boolean;
}
export declare function time(name: string, config?: TimeConfig): PgTimeBuilder<ColumnData<string>, ColumnNotNull<false>, ColumnHasDefault<false>>;

@@ -30,4 +30,5 @@ import { ColumnData, ColumnDriverParam, ColumnHasDefault, ColumnNotNull, TableName } from 'drizzle-orm/branded-types';

}
export declare type PrecisionLimit = 0 | 1 | 2 | 3 | 4 | 5 | 6;
export declare type TimestampConfig<TMode extends 'string' | 'date' = 'string' | 'date'> = {
precision?: number;
precision?: PrecisionLimit;
} & ({

@@ -34,0 +35,0 @@ mode: TMode;

@@ -13,3 +13,7 @@ import { ColumnData, ColumnDriverParam, ColumnHasDefault, ColumnNotNull, TableName } from 'drizzle-orm/branded-types';

}
export declare function varchar(name: string, length?: number): PgVarcharBuilder;
export declare function varchar<T extends string = string>(name: string, length?: number): PgVarcharBuilder<ColumnData<T>>;
export declare function varchar(name: string, config?: {
length?: number;
}): PgVarcharBuilder;
export declare function varchar<T extends string = string>(name: string, config?: {
length?: number;
}): PgVarcharBuilder<ColumnData<T>>;

@@ -26,6 +26,6 @@ "use strict";

exports.PgVarchar = PgVarchar;
function varchar(name, length) {
return new PgVarcharBuilder(name, length);
function varchar(name, config) {
return new PgVarcharBuilder(name, config === null || config === void 0 ? void 0 : config.length);
}
exports.varchar = varchar;
//# sourceMappingURL=varchar.js.map
{
"name": "drizzle-orm-pg",
"version": "0.12.0-beta.10",
"version": "0.12.0-beta.11",
"description": "Drizzle ORM package for PostgreSQL database",

@@ -5,0 +5,0 @@ "main": "index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc