Dominic Hadfield
11/29/2020, 9:16 PMTypeError: Cannot read property 'onError' of undefined
at Socket.onSocketClose (/var/task/node_modules/@prisma/client/runtime/index.js:25673)
at Socket.emit (events.js:314)
at Socket.EventEmitter.emit (domain.js:483)
at Pipe.<anonymous> (net.js:676)
Bohdan Kolosovsky
11/30/2020, 12:36 PM@Field(() => [Int])
lengthIds: number[];
I need to write filter:
findMany({
where: {
length_ids:{
in: objectDto.filter.lengthIds
}
}
})
Bohdan Kolosovsky
11/30/2020, 12:36 PMBohdan Kolosovsky
11/30/2020, 12:59 PMJohn Peña
12/17/2020, 9:34 PMgkze
12/30/2020, 10:45 PMfindMany
is not supported, I am currently doing a nested findMany
(the schema has an m-n relationship between the models) for each object in the results. Is there a better way to achieve this?Cheese
01/07/2021, 11:46 PMstephen.pearl
01/08/2021, 11:22 PMCheese
01/11/2021, 2:27 PMexport async function getServerSideProps({ params }) {
const users = await prisma.user.findMany({
where: {
createdAt: new Date(),
name: params.toString()
}
})
return {
props : { users }
}
}
export default function UserPage({users}){
return (
<>
<Head>
<title>{users.username}</title>
</Head>
<Nav />
<div key={users.id}>
<h1>{users.username}</h1>
<p>{users.bio}</p>
</div>
</>
)
}
Cheese
01/13/2021, 11:39 PMTypeError: Cannot read property 'name' of null
Here's my code snippet:
export async function getServerSideProps({ params }) {
const users = await prisma.user.findUnique({
where: {
name: params.toString()
}
})
return {
props: { users }
}
}
Cheese
01/14/2021, 12:01 AMCheese
01/14/2021, 12:01 AMparams.toString()
to params.username.toString()
Tyler Storm
01/14/2021, 10:29 PMfindUnique
app | 2021-01-14 17:15:54 22:15:54.928Z ERROR App-Backend:
app | 2021-01-14 17:15:54 Query engine exited with code 255
app | 2021-01-14 17:15:54 PANIC in /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tide-0.15.0/src/listener/unix_listener.rs:152:22
app | 2021-01-14 17:15:54 Could not canonicalize path dir
app | 2021-01-14 17:15:54 --
app | 2021-01-14 17:15:54 Error: Query engine exited with code 255
app | 2021-01-14 17:15:54 PANIC in /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tide-0.15.0/src/listener/unix_listener.rs:152:22
app | 2021-01-14 17:15:54 Could not canonicalize path dir
app | 2021-01-14 17:15:54 at PrismaClientFetcher.request (/app/backend/node_modules/@prisma/client/runtime/index.js:78136:15)
app | 2021-01-14 17:15:54 at processTicksAndRejections (internal/process/task_queues.js:97:5)
Any idea what is happening here? This doesn’t seem to happen to me locally on my macbook but does occur when on my docker deployed to kubernettesÖmer Özdemir
01/22/2021, 12:35 PMts-node
but when I try to compile it with tsc
I get this errorMartïn
01/23/2021, 3:50 PMActor_profileId_fkey (index)
at PrismaClientFetcher.request (C:\fode\mtchero\node_modules\@prisma\client\runtime\index.js7845515). {`
code: 'P2003',
clientVersion: '2.15.0',
meta: { field_name: 'Actor_profileId_fkey (index)' }
}
stephen.pearl
01/26/2021, 3:23 PMupdateOneEntity
(where entity is any object) I'm using the crud generated objects and I have no idea what the syntax of the input is.SeekTheError
02/04/2021, 2:38 PM(...) /webpack:/libs/data/src/generated/client/index.js:21
const debug = debugLib('prisma-client')
^
TypeError: debugLib is not a function
The prisma dependencies I have installed in my package.json are:
"@prisma/client": "2.16",
"prisma": "^2.16.0",
and my schema.prisma generator config is:
generator client {
provider = "prisma-client-js"
output = "./generated/client"
previewFeatures = ["nativeTypes"]
binaryTargets = ["native", "rhel-openssl-1.0.x"]
}
Please let me know if I should ask about this somewhere else.
Thanks a lotTyler Storm
02/04/2021, 7:37 PMInvalid `prisma.user.findMany()` invocation:
Can't reach database server at `MY_DB_URL`:`MY_DB_PORT`
Please make sure your database server is running at `MY_DB_URL`:`MY_DB_PORT`.
at PrismaClientFetcher.request (/Users/tyler/prismaproject/node_modules/@prisma/client/runtime/index.js:78463:15)
at processTicksAndRejections (internal/process/task_queues.js:94:5)
Whenever looking up a large quantity of records I get an error saying unable to reach database server. The same query works with less records but seems to be timing out.
Found more info on github incase anyone searches the slack here is the link https://github.com/prisma/prisma/issues/4280Yousuf Hasan
02/05/2021, 12:09 AMcreateMany
doesn't support nesting and create
method gets v slow and has performance issues. I have already raised couple of issues https://github.com/prisma/prisma/issues/5474 and https://github.com/prisma/prisma/issues/5475Yousuf Hasan
02/05/2021, 3:05 AMTanmay Naik
02/08/2021, 10:38 AM李白字一日
02/09/2021, 10:44 AMThe change you are trying to make would violate the required relation 'threadTouser' between the `thread` and `user` models.
李白字一日
02/09/2021, 10:44 AMYousuf Hasan
02/10/2021, 5:49 AMTanmay Naik
02/10/2021, 1:04 PMCaleb Hyatt
02/15/2021, 4:22 PM/api/createMember
endpoint.Caleb Hyatt
02/15/2021, 4:23 PMcreateMember
endpoint:Caleb Hyatt
02/15/2021, 4:40 PMTanmay Naik
02/16/2021, 7:49 AMJamey Nakama
02/16/2021, 6:22 PMseed
which file to use? It’s a common need to have different seeds, for say local dev, tests, maybe qa, maybe some special case.