Allows you to perform aggregations operations on a GuildRandomMessage.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Select which aggregations you would like to apply and on what fields.
Count the number of GuildRandomMessages.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Optionalargs: Subset<T, GuildRandomMessageCountArgs<DefaultArgs>>Arguments to filter GuildRandomMessages to count.
Create a GuildRandomMessage.
Arguments to create a GuildRandomMessage.
Create many GuildRandomMessages.
Optionalargs: SelectSubset<T, GuildRandomMessageCreateManyArgs<ExtArgs>>Arguments to create many GuildRandomMessages.
Create many GuildRandomMessages and returns the data saved in the database.
Optionalargs: SelectSubset<T, GuildRandomMessageCreateManyAndReturnArgs<ExtArgs>>Arguments to create many GuildRandomMessages.
// Create many GuildRandomMessages
const guildRandomMessage = await prisma.guildRandomMessage.createManyAndReturn({
data: [
// ... provide data here
]
})
// Create many GuildRandomMessages and only return the `dbId`
const guildRandomMessageWithDbIdOnly = await prisma.guildRandomMessage.createManyAndReturn({
select: { dbId: true },
data: [
// ... provide data here
]
})
Note, that providing `undefined` is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Delete a GuildRandomMessage.
Arguments to delete one GuildRandomMessage.
Delete zero or more GuildRandomMessages.
Optionalargs: SelectSubset<T, GuildRandomMessageDeleteManyArgs<ExtArgs>>Arguments to filter GuildRandomMessages to delete.
Find the first GuildRandomMessage that matches the filter.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Optionalargs: SelectSubset<T, GuildRandomMessageFindFirstArgs<ExtArgs>>Arguments to find a GuildRandomMessage
Find the first GuildRandomMessage that matches the filter or
throw PrismaKnownClientError with P2025 code if no matches were found.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Optionalargs: SelectSubset<T, GuildRandomMessageFindFirstOrThrowArgs<ExtArgs>>Arguments to find a GuildRandomMessage
Find zero or more GuildRandomMessages that matches the filter.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Optionalargs: SelectSubset<T, GuildRandomMessageFindManyArgs<ExtArgs>>Arguments to filter and select certain fields only.
// Get all GuildRandomMessages
const guildRandomMessages = await prisma.guildRandomMessage.findMany()
// Get first 10 GuildRandomMessages
const guildRandomMessages = await prisma.guildRandomMessage.findMany({ take: 10 })
// Only select the `dbId`
const guildRandomMessageWithDbIdOnly = await prisma.guildRandomMessage.findMany({ select: { dbId: true } })
Find zero or one GuildRandomMessage that matches the filter.
Arguments to find a GuildRandomMessage
Find one GuildRandomMessage that matches the filter or throw an error with error.code='P2025'
if no matches were found.
Arguments to find a GuildRandomMessage
Group by GuildRandomMessage.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Group by arguments.
Update one GuildRandomMessage.
Arguments to update one GuildRandomMessage.
Update zero or more GuildRandomMessages.
Note, that providing undefined is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Arguments to update one or more rows.
Update zero or more GuildRandomMessages and returns the data updated in the database.
Arguments to update many GuildRandomMessages.
// Update many GuildRandomMessages
const guildRandomMessage = await prisma.guildRandomMessage.updateManyAndReturn({
where: {
// ... provide filter here
},
data: [
// ... provide data here
]
})
// Update zero or more GuildRandomMessages and only return the `dbId`
const guildRandomMessageWithDbIdOnly = await prisma.guildRandomMessage.updateManyAndReturn({
select: { dbId: true },
where: {
// ... provide filter here
},
data: [
// ... provide data here
]
})
Note, that providing `undefined` is treated as the value not being there.
Read more here: https://pris.ly/d/null-undefined
Create or update one GuildRandomMessage.
Arguments to update or create a GuildRandomMessage.
// Update or create a GuildRandomMessage
const guildRandomMessage = await prisma.guildRandomMessage.upsert({
create: {
// ... data to create a GuildRandomMessage
},
update: {
// ... in case it already exists, update
},
where: {
// ... the filter for the GuildRandomMessage we want to update
}
})
Fields of the GuildRandomMessage model