Given exponent overflowing the maximum accepted scale (255).: TryFromIntError(())
See original GitHub issueHi Prisma Team! My Prisma Client just crashed. This is the report:
Versions
Name | Version |
---|---|
Node | v16.16.0 |
OS | linux-musl |
Prisma Client | 4.2.1 |
Query Engine | 2920a97877e12e055c1333079b8d19cee7f33826 |
Database | sqlserver |
Logs
prisma:tryLoadEnv Environment variables not found at null
prisma:tryLoadEnv Environment variables not found at undefined
prisma:tryLoadEnv No Environment variables loaded
prisma:tryLoadEnv Environment variables not found at null
prisma:tryLoadEnv Environment variables not found at undefined
prisma:tryLoadEnv No Environment variables loaded
prisma:client dirname /opt/bku-sync-final/node_modules/@@internal/prisma/client/sqlserver/cabang
prisma:client relativePath ../../../../../../src/util/db/sqlserver
prisma:client cwd /opt/bku-sync-final/src/util/db/sqlserver
prisma:client clientVersion 4.2.1
prisma:client clientEngineType library
prisma:client:libraryEngine internalSetup
prisma:client:libraryEngine:loader Searching for Query Engine Library in /opt/bku-sync-final/node_modules/@@internal/prisma/client/.prisma/client
prisma:client:libraryEngine:loader Searching for Query Engine Library in /opt/bku-sync-final/node_modules/@@internal/prisma/client/sqlserver/cabang
prisma:client:libraryEngine:loader loadEngine using /opt/bku-sync-final/node_modules/@@internal/prisma/client/sqlserver/cabang/libquery_engine-linux-musl.so.node
prisma:client:libraryEngine sending request, this.libraryStarted: false
prisma:client:libraryEngine library starting
prisma:client:libraryEngine library started
Client Snippet
// PLEASE FILL YOUR CODE SNIPPET HERE
dbContext.aktivasi_bku
.upsert({
where: {
id_anggaran_id_periode: {
id_anggaran: data.id_anggaran,
id_periode: data.id_periode,
},
},
create: data,
update: data,
})
Schema
// PLEASE ADD YOUR SCHEMA HERE IF POSSIBLE
model aktivasi_bku {
id_anggaran String @db.Uuid
id_periode Decimal @db.Decimal(2, 0)
tanggal_aktivasi DateTime @db.Timestamp(6)
tanggal_finish DateTime? @db.Timestamp(6)
saldo_awal_bank Decimal? @db.Money
saldo_awal_tunai Decimal? @db.Money
saldo_akhir_bank Decimal? @db.Money
saldo_akhir_tunai Decimal? @db.Money
saldo_awal_bank_sisa Decimal? @db.Money
saldo_awal_tunai_sisa Decimal? @db.Money
saldo_akhir_bank_sisa Decimal? @db.Money
saldo_akhir_tunai_sisa Decimal? @db.Money
soft_delete Decimal @db.Decimal(1, 0)
create_date DateTime @db.Timestamp(6)
last_update DateTime @db.Timestamp(6)
updater_id String? @db.Uuid
anggaran anggaran @relation(fields: [id_anggaran], references: [id_anggaran], onUpdate: Restrict, map: "FK_aktivasi_bku_anggaran_id_anggaran")
ref_periode ref_periode @relation(fields: [id_periode], references: [id_periode], onUpdate: Restrict, map: "FK_aktivasi_bku_ref_periode_id_periode")
report_bku report_bku[]
@@id([id_anggaran, id_periode], map: "PK_aktivasi_bku")
@@index([id_periode], map: "IX_aktivasi_bku_id_periode")
}
Prisma Engine Query
{"X":{}}
Issue Analytics
- State:
- Created a year ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Given exponent overflowing the maximum accepted scale ...
The only place where we throw this is when somebody creates a BigDecimal with a scale that is bigger than 255, then tries...
Read more >TryFromIntError usage - rust - Stack Overflow
TryFromIntError is a tuple struct with private fields (hence the (_) in the documentation). The type doesn't expose any way to construct an ......
Read more >Prisma 4.4.0 Release - GitClear
test(client): int overflow #13913 (#15545). Authored September 27, 2022 ... Given exponent overflowing the maximum accepted scale (255).
Read more >TryFromIntError in std::num - Rust
The error type returned when a checked integral type conversion fails.
Read more >mod.rs.html -- source
Operations like `+` on `u32` values is intended to never overflow, /// and in some debug configurations overflow is detected and results ///...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@danstarns @Jolg42 here’s the data I tried to upsert:
nice info. thanks… 😃 👍