Order by `rowid`?

Is it possible to order by (SQLite) rowid? I need to order by rowid as my table has no other natural sorting column.
const driverFamilyRelationships = await c.var.f1db.driverFamilyRelationship.findMany({
where: {
AND: [{ driverId: driverId }, pageableQueryOptions.where],
},
orderBy: [
// TODO: { _raw: Prisma.sql`rowid` },
...pageableQueryOptions.orderBy,
],
skip: pageableQueryOptions.skip,
take: pageableQueryOptions.take,
});
const driverFamilyRelationships = await c.var.f1db.driverFamilyRelationship.findMany({
where: {
AND: [{ driverId: driverId }, pageableQueryOptions.where],
},
orderBy: [
// TODO: { _raw: Prisma.sql`rowid` },
...pageableQueryOptions.orderBy,
],
skip: pageableQueryOptions.skip,
take: pageableQueryOptions.take,
});
1 Reply
Marcel Overdijk
Marcel OverdijkOP2mo ago
Bump. Anyone an idea if this is possible?
Want results from more Discord servers?
Add your server