tables.ts — drizzle-orm Source File
Architecture documentation for tables.ts, a typescript file in the drizzle-orm codebase. 9 imports, 5 dependents.
Entity Profile
Dependency Diagram
graph LR 42a3f195_439f_04bb_e0a7_1cdfc016e10c["tables.ts"] 9c290d96_894a_8e33_3455_d9f3a1fa1518["db.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 9c290d96_894a_8e33_3455_d9f3a1fa1518 3f58c8f4_b305_acb0_933a_0541231c5109["node:crypto"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 3f58c8f4_b305_acb0_933a_0541231c5109 25b05299_f48f_bceb_01ca_1343d330a8f7["utils.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 25b05299_f48f_bceb_01ca_1343d330a8f7 2dc784c6_95e9_4e28_ec81_7caf4acbd426["column-builder.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 2dc784c6_95e9_4e28_ec81_7caf4acbd426 cf530c77_bff8_0def_5c6c_6cf067e6c757["index.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> cf530c77_bff8_0def_5c6c_6cf067e6c757 5fcf5683_027c_7085_e2c2_a707894ae3e5["schema.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 5fcf5683_027c_7085_e2c2_a707894ae3e5 5c46beaf_8b59_d2e3_def3_8af6daf1fccd["index.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 5c46beaf_8b59_d2e3_def3_8af6daf1fccd 1fd6ac27_a0fb_a054_a358_c8766c3fcbd7["table.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> 1fd6ac27_a0fb_a054_a358_c8766c3fcbd7 ecce3253_1e75_a87f_27b3_ca87e81a3024["utils.ts"] 42a3f195_439f_04bb_e0a7_1cdfc016e10c --> ecce3253_1e75_a87f_27b3_ca87e81a3024 043a8c47_84a8_3ccf_0ea2_e24177d8b67a["delete.ts"] 043a8c47_84a8_3ccf_0ea2_e24177d8b67a --> 42a3f195_439f_04bb_e0a7_1cdfc016e10c f2d4047f_933a_1408_3dfc_f6ba5822fe89["insert.ts"] f2d4047f_933a_1408_3dfc_f6ba5822fe89 --> 42a3f195_439f_04bb_e0a7_1cdfc016e10c 1b29b8f2_7157_9d62_ee9d_e1c3725e1a73["select.ts"] 1b29b8f2_7157_9d62_ee9d_e1c3725e1a73 --> 42a3f195_439f_04bb_e0a7_1cdfc016e10c 29eb88b7_5703_fbfd_799a_db691267996d["set-operators.ts"] 29eb88b7_5703_fbfd_799a_db691267996d --> 42a3f195_439f_04bb_e0a7_1cdfc016e10c 76d584e5_2f41_6cf2_3735_7f9bdfc4a399["update.ts"] 76d584e5_2f41_6cf2_3735_7f9bdfc4a399 --> 42a3f195_439f_04bb_e0a7_1cdfc016e10c style 42a3f195_439f_04bb_e0a7_1cdfc016e10c fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import * as crypto from 'node:crypto';
import { type Equal, Expect } from 'type-tests/utils.ts';
import type { BuildColumn } from '~/column-builder.ts';
import {
bigint,
binary,
boolean,
char,
customType,
date,
datetime,
decimal,
double,
float,
index,
int,
json,
longtext,
mediumint,
mediumtext,
primaryKey,
real,
serial,
type SingleStoreColumn,
singlestoreEnum,
singlestoreTable,
smallint,
text,
time,
timestamp,
tinyint,
tinytext,
unique,
uniqueIndex,
varbinary,
varchar,
vector,
year,
} from '~/singlestore-core/index.ts';
import { singlestoreSchema } from '~/singlestore-core/schema.ts';
import { eq } from '~/sql/expressions/index.ts';
/* import { singlestoreView, type SingleStoreViewWithSelection } from '~/singlestore-core/view.ts'; */
import type { InferSelectModel } from '~/table.ts';
import type { Simplify } from '~/utils.ts';
import { db } from './db.ts';
export const users = singlestoreTable(
'users_table',
{
id: serial('id').primaryKey(),
homeCity: int('home_city')
.notNull(),
currentCity: int('current_city'),
serialNullable: serial('serial1'),
serialNotNull: serial('serial2').notNull(),
class: text('class', { enum: ['A', 'C'] }).notNull(),
subClass: text('sub_class', { enum: ['B', 'D'] }),
text: text('text'),
age1: int('age1').notNull(),
createdAt: timestamp('created_at', { mode: 'date' }).notNull().defaultNow(),
// ... (968 more lines)
Domain
Subdomains
Functions
Dependencies
- column-builder.ts
- db.ts
- index.ts
- index.ts
- node:crypto
- schema.ts
- table.ts
- utils.ts
- utils.ts
Imported By
Source
Frequently Asked Questions
What does tables.ts do?
tables.ts is a source file in the drizzle-orm codebase, written in typescript. It belongs to the DrizzleORM domain, DatabaseDrivers subdomain.
What functions are defined in tables.ts?
tables.ts defines 13 function(s): cities, citiesCustom, classes, customOptionalConfig.dataType, customOptionalConfig.fromDriver, customOptionalConfig.toDriver, customRequiredConfig.dataType, customRequiredConfig.fromDriver, customRequiredConfig.toDriver, customText.dataType, and 3 more.
What does tables.ts depend on?
tables.ts imports 9 module(s): column-builder.ts, db.ts, index.ts, index.ts, node:crypto, schema.ts, table.ts, utils.ts, and 1 more.
What files import tables.ts?
tables.ts is imported by 5 file(s): delete.ts, insert.ts, select.ts, set-operators.ts, update.ts.
Where is tables.ts in the architecture?
tables.ts is located at drizzle-orm/type-tests/singlestore/tables.ts (domain: DrizzleORM, subdomain: DatabaseDrivers, directory: drizzle-orm/type-tests/singlestore).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free