Jokerz
Jokerz
Explore posts from servers
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
hey, what do you mean by split my search?
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
and search for each
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
or i need to split my search term up
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
so like if i have a object with value 1 2 3 in the keywords field and search 3 2 1 it should find it?
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
im guessing cant match multiple parts because then a would return everything
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
i am now using this, which works great say if a watch is called rolex daytona gold and i search rolex daytona im going to get that watch but if i search rolex gold its not going to appear there is this ilike filter only searching in order through the string or can i match multiple parts?
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
where: ilike(schema.watch.keywords, `%${input.name}%`),
where: ilike(schema.watch.keywords, `%${input.name}%`),
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
have a new interesting situation
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
i decided to create a new field keywords and populate it with the brand + family name with the watch name
13 replies
DTDrizzle Team
Created by Jokerz on 2/15/2024 in #help
can we filter by a prop on a relation during a query?
hey @Mykhailo thanks for the advice
13 replies
DTDrizzle Team
Created by Jokerz on 7/8/2023 in #help
foreign key constraint cannot be implemented
figured it out, it doesnt like the uuid column type, fine if i change back to serial
2 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
Any thoughts on this?
11 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
11 replies
DTDrizzle Team
Created by philbookst on 5/11/2023 in #help
uuid missing in drizzle-orm/mysql-core?
nice!
12 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
thanks man ❤️
11 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
import { sql } from "drizzle-orm";
import {
serial,
int,
text,
timestamp,
mysqlTable,
} from "drizzle-orm/mysql-core";

export const userTeams = mysqlTable("user_leagues", {
id: serial("id").primaryKey(),
userId: int("user_id").notNull(),
name: text("name").notNull(),
leagueId: int("league_id").notNull(),
abbreviation: text("abbreviation").notNull(),
teamLogo: text("team_logo").notNull(),
createdAt: timestamp("created_at")
.notNull()
.default(sql`CURRENT_TIMESTAMP`),
});
import { sql } from "drizzle-orm";
import {
serial,
int,
text,
timestamp,
mysqlTable,
} from "drizzle-orm/mysql-core";

export const userTeams = mysqlTable("user_leagues", {
id: serial("id").primaryKey(),
userId: int("user_id").notNull(),
name: text("name").notNull(),
leagueId: int("league_id").notNull(),
abbreviation: text("abbreviation").notNull(),
teamLogo: text("team_logo").notNull(),
createdAt: timestamp("created_at")
.notNull()
.default(sql`CURRENT_TIMESTAMP`),
});
this was the seperate table i was working on
11 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
and when i was building on another table, and trying to push that to the database i got this
11 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
i imported and set data, 689 players
11 replies
DTDrizzle Team
Created by Jokerz on 6/6/2023 in #help
When trying to push:mysql its warning that schema has changed and data will be lost when it hasnt.
import { sql } from "drizzle-orm";
import {
serial,
int,
text,
timestamp,
mysqlTable,
boolean,
mysqlEnum,
decimal,
} from "drizzle-orm/mysql-core";

export const players = mysqlTable("players", {
id: serial("id").primaryKey(),
rapidApi: int("rapid_api").notNull(),
proTeamId: int("pro_team_id").notNull(),
proLeagueId: int("pro_league_id").notNull(),
name: text("name").notNull(),
age: int("age"),
number: int("number"),
photo: text("photo").notNull(),
position: mysqlEnum("position", [
"Goalkeeper",
"Defender",
"Midfielder",
"Attacker",
]).notNull(),
ranking: int("ranking"),
projectedPoints: decimal("projected_points"),
createdAt: timestamp("created_at")
.notNull()
.default(sql`CURRENT_TIMESTAMP`),
});
import { sql } from "drizzle-orm";
import {
serial,
int,
text,
timestamp,
mysqlTable,
boolean,
mysqlEnum,
decimal,
} from "drizzle-orm/mysql-core";

export const players = mysqlTable("players", {
id: serial("id").primaryKey(),
rapidApi: int("rapid_api").notNull(),
proTeamId: int("pro_team_id").notNull(),
proLeagueId: int("pro_league_id").notNull(),
name: text("name").notNull(),
age: int("age"),
number: int("number"),
photo: text("photo").notNull(),
position: mysqlEnum("position", [
"Goalkeeper",
"Defender",
"Midfielder",
"Attacker",
]).notNull(),
ranking: int("ranking"),
projectedPoints: decimal("projected_points"),
createdAt: timestamp("created_at")
.notNull()
.default(sql`CURRENT_TIMESTAMP`),
});
11 replies
DTDrizzle Team
Created by philbookst on 5/11/2023 in #help
uuid missing in drizzle-orm/mysql-core?
interested how you went about implementing this
12 replies