SilentSean
SilentSean
Explore posts from servers
RRailway
Created by SilentSean on 4/26/2024 in #✋|help
Railway sending emails from my domain
The only service I have running at the moment is a postgres instance, nothing else has been deployed
8 replies
RRailway
Created by SilentSean on 4/26/2024 in #✋|help
Railway sending emails from my domain
No description
8 replies
RRailway
Created by SilentSean on 4/26/2024 in #✋|help
Railway sending emails from my domain
N/A
8 replies
DTDrizzle Team
Created by SilentSean on 5/7/2023 in #help
Migration failure on fresh DB
Awesome, thanks! Yeah, I have drizzle kit 0.17.6 at the moment.
9 replies
DTDrizzle Team
Created by SilentSean on 5/7/2023 in #help
Migration failure on fresh DB
Yep, everything is exported.
import { pgEnum, pgTable, uuid, varchar } from 'drizzle-orm/pg-core';

export const grandCompany = pgEnum('grandCompany', ['Unknown', 'Maelstrom', 'Adder', 'Flames']);

export const character = pgTable('character', {
id: uuid('id').defaultRandom().primaryKey(),
xivId: varchar('xivId').notNull(),

server: varchar('server').notNull(),
dc: varchar('dc').notNull(),
name: varchar('name').notNull(),

grandCompany: grandCompany('grandCompany'),
});
import { pgEnum, pgTable, uuid, varchar } from 'drizzle-orm/pg-core';

export const grandCompany = pgEnum('grandCompany', ['Unknown', 'Maelstrom', 'Adder', 'Flames']);

export const character = pgTable('character', {
id: uuid('id').defaultRandom().primaryKey(),
xivId: varchar('xivId').notNull(),

server: varchar('server').notNull(),
dc: varchar('dc').notNull(),
name: varchar('name').notNull(),

grandCompany: grandCompany('grandCompany'),
});
DO $$ BEGIN
CREATE TYPE "grandCompany" AS ENUM('Unknown', 'Maelstrom', 'Adder', 'Flames');
EXCEPTION
WHEN duplicate_object THEN null;
END $$;

CREATE TABLE IF NOT EXISTS "character" (
"id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
"xivId" varchar NOT NULL,
"server" varchar NOT NULL,
"dc" varchar NOT NULL,
"name" varchar NOT NULL,
"grandCompany" grandCompany
);
DO $$ BEGIN
CREATE TYPE "grandCompany" AS ENUM('Unknown', 'Maelstrom', 'Adder', 'Flames');
EXCEPTION
WHEN duplicate_object THEN null;
END $$;

CREATE TABLE IF NOT EXISTS "character" (
"id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
"xivId" varchar NOT NULL,
"server" varchar NOT NULL,
"dc" varchar NOT NULL,
"name" varchar NOT NULL,
"grandCompany" grandCompany
);
9 replies