Gamius
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
I have to solve the problem like a other way
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
Thank you.
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
Ah okay
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
thats the way I patch the data in the db
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
const user = ctx.table("users").getX("clerkId", identity.tokenIdentifier);
const updates: { email?: string; lastName?: string; firstName?: string } =
{};
if (args.data.email) {
updates.email = args.data.email;
}
if (args.data.lastName) {
updates.lastName = args.data.lastName;
}
if (args.data.firstName) {
updates.firstName = args.data.firstName;
}
// Use one patch instead of a few singular patches for better performance
try {
await user.patch(updates);
await ctx.scheduler.runAfter(0, internal.users.updateUserDataClerk, {
data: args.data,
identity: identity.tokenIdentifier,
});
} catch (e) {
console.error(e);
if (e instanceof Error && e.message.includes("email")) {
throw new Error("Email already in use");
17 replies
CCConvex Community
•Created by Gamius on 12/19/2024 in #support-community
unique() query returned more than one result
17 replies
CCConvex Community
•Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/2/2024 in #support-community
Clerk: Wait until Convex also set up the user
Can I send you the Github repo?
85 replies
CCConvex Community
•Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/2/2024 in #support-community
Clerk: Wait until Convex also set up the user
I hope its okey for you that i pinged you ...
85 replies
CCConvex Community
•Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/2/2024 in #support-community
Clerk: Wait until Convex also set up the user
Hey @erquhart,
Ive seen you helped fleetadmiraljakob yesterday on another problem.
I work with fleetadmiraljakob on a Chat app.
Maybe you can help us with this problem?
85 replies