Oluwasetemi Ojo
07/29/2021, 3:48 PMprisma.price.create()` invocation:\n\n\n Error occurred during query execution:\nConnectorError(ConnectorError { user_facing_error: None, kind: RawError { code: \"263\", message: \"Cannot create namespace groovy_db.Price in multi-document transaction.\" } })
Oluwasetemi Ojo
07/29/2021, 3:48 PMOluwasetemi Ojo
07/29/2021, 3:49 PMDATABASE_URL="<mongodb://localhost:27017/groovy_db?replicaSet=rs0>"
Oluwasetemi Ojo
07/29/2021, 3:54 PMChip Clark
07/29/2021, 3:59 PMconst whereClause = {
{
License: {
every: {
LicenseTypeID: license
}
}
}
};
Regardless of whether I user every: or some: it pulls all the records. There is no filtering going on.
return Promise.all([
this.prisma.person.findMany({
take: perPage,
skip,
where: whereClause,
include: defaultIncludeQuery
})
khareta
07/29/2021, 4:43 PMVal Neekman
07/29/2021, 10:39 PMDregond
07/30/2021, 3:49 AMDregond
07/30/2021, 3:49 AMOption::unwrap()
on a None
valueGelo
07/30/2021, 5:54 AMArun Kumar
07/30/2021, 8:18 AMnpx prisma migrate dev
command.
Error: P3006
Migration `20210729200626_changing_the_id_and_id_referral_to_int` failed to apply cleanly to the shadow database.
Error:
Database error
Error querying the database: db error: ERROR: syntax error at or near ","
0: sql_migration_connector::flavour::postgres::sql_schema_from_migration_history
at migration-engine\connectors\sql-migration-connector\src\flavour\<http://postgres.rs:367|postgres.rs:367>
1: sql_migration_connector::validate_migrations
at migration-engine\connectors\sql-migration-connector\src\<http://lib.rs:322|lib.rs:322>
2: migration_core::api::DevDiagnostic
at migration-engine\core\src\<http://api.rs:89|api.rs:89>
user
07/30/2021, 8:18 AMPatrick
07/30/2021, 2:39 PMasync getUserByMail(email: string): Promise<User | null> {
// return this.prisma.user.findUnique({ where: { email } }); // <- this works
// this fails in unit tests:
return this.prisma.user.findFirst({
where: {
email: {
equals: email,
mode: 'insensitive',
},
},
});
}
Anybody knows what the issue could be? findUnique
works fine, but I need to find the mail case insensitive and findUnique
doesnt seem to support this.Christoph Dietrich
07/30/2021, 3:14 PMOluwasetemi Ojo
07/30/2021, 3:17 PMHalvor
07/30/2021, 3:35 PM@@unique(fields: [arbitratedId, userId])
Charles Dimino
07/30/2021, 6:02 PMhayes
07/30/2021, 11:49 PMalisalimli
07/31/2021, 6:52 AMalisalimli
07/31/2021, 6:52 AM[13/14] RUN npx prisma migrate deploy:#18 5.127 Prisma schema loaded from prisma/schema.prisma #18 5.278 Error: Get config: /abb/node_modules/prisma/node_modules/@prisma/engines/query-engine-debian-openssl-1.1.x: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory ------ executor failed running [/bin/sh -c npx prisma migrate deploy]: exit code: 1
Mohammed Alrea
07/31/2021, 7:18 AMjasci
07/31/2021, 10:01 AMPhil Bookst
07/31/2021, 10:54 AMKiên Trần
07/31/2021, 12:17 PMHalvor
07/31/2021, 6:31 PM@@unique(fields: [arbitratedId, userId])
A DSJ
08/01/2021, 2:37 PMmodel User {
id String @id @default(uuid())
email String @unique
role Role @default(USER)
group Group? @relation(fields: [group_id], references: [id], onDelete: SetNull)
group_id String
created_at DateTime @default(now())
updated_at DateTime @updatedAt
@@map("user")
}
model Group {
id String @id @default(uuid())
name String
users User[]
created_at DateTime @default(now())
updated_at DateTime @updatedAt
deleted Boolean @default(false)
@@map("group")
}
How can I make this list of User when I already have users User[] for the relation in User model ?
(BTW i've read the doc but i'm totally lost...)
Thanks a lot !John Benton
08/02/2021, 1:14 PMmodel Match {
id String @id
team1 User[]
team2 User[]
}
model User {
id String @id
matches Match[]
}
John Benton
08/02/2021, 1:14 PMJohn Benton
08/02/2021, 1:16 PM