@drzl/analyzer 1.21.2 → 1.21.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.cts +28 -5
- package/dist/index.d.ts +28 -5
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -156,11 +156,34 @@ interface Column {
|
|
|
156
156
|
* `declaredDecimalRange` reads both numbers now, the two are distinguishable, and each says what
|
|
157
157
|
* its own server does.
|
|
158
158
|
*
|
|
159
|
-
* Postgres and Gel. MySQL
|
|
160
|
-
*
|
|
161
|
-
*
|
|
162
|
-
*
|
|
163
|
-
*
|
|
159
|
+
* Postgres and Gel. MySQL is a `false` on every one of these, and the reason is worth writing
|
|
160
|
+
* down carefully, because the two client paths give different answers and only one of them is
|
|
161
|
+
* the path a driver takes.
|
|
162
|
+
*
|
|
163
|
+
* Measured on MySQL 8.4.11 in `STRICT_TRANS_TABLES`, through mysql2's `execute()`, which is the
|
|
164
|
+
* binary prepared path drizzle uses:
|
|
165
|
+
*
|
|
166
|
+
* float, double all three refused, `Out of range value`
|
|
167
|
+
* decimal(10,2) all three STORED AS 0.00, silently, `SHOW WARNINGS` empty
|
|
168
|
+
* int `NaN` stored as 0 silently; both infinities refused
|
|
169
|
+
* bigint `NaN` stored as the int64 minimum silently; both infinities refused
|
|
170
|
+
*
|
|
171
|
+
* A control rules out ordinary overflow as the explanation: a finite `1e308` into the same
|
|
172
|
+
* `decimal(10,2)` is refused. So on three of those five, the server takes the row and stores a
|
|
173
|
+
* number nobody sent. This comment used to say a decimal "refuses them outright", which is the
|
|
174
|
+
* *text* path's answer: through the `mysql` CLI the same value answers `Incorrect decimal value`.
|
|
175
|
+
* Both statements are true of their own path, and only one of them describes what a validator
|
|
176
|
+
* sits in front of.
|
|
177
|
+
*
|
|
178
|
+
* The flag stays `false` on all of them, so the emitted schemas refuse all three. That is
|
|
179
|
+
* deliberately not the "never be stricter than the server" rule the range work follows: the
|
|
180
|
+
* server is not accepting the value here, it is accepting the row and storing a different value,
|
|
181
|
+
* and a validator whose whole job is to say what the database will do with a write cannot call
|
|
182
|
+
* that acceptance. Nothing is lost either way, since every generator's plain number type already
|
|
183
|
+
* refuses the three.
|
|
184
|
+
*
|
|
185
|
+
* SQLite returns both infinities and silently turns `NaN` into NULL, which is real and is filed
|
|
186
|
+
* on its own: a column needs both halves of that answer or none.
|
|
164
187
|
*
|
|
165
188
|
* Gel joined on a measurement of its own rather than on being Postgres-backed: a live Gel 7.1
|
|
166
189
|
* stored `nan`, `inf` and `-inf` in both `std::float32` and `std::float64` and handed all three
|
package/dist/index.d.ts
CHANGED
|
@@ -156,11 +156,34 @@ interface Column {
|
|
|
156
156
|
* `declaredDecimalRange` reads both numbers now, the two are distinguishable, and each says what
|
|
157
157
|
* its own server does.
|
|
158
158
|
*
|
|
159
|
-
* Postgres and Gel. MySQL
|
|
160
|
-
*
|
|
161
|
-
*
|
|
162
|
-
*
|
|
163
|
-
*
|
|
159
|
+
* Postgres and Gel. MySQL is a `false` on every one of these, and the reason is worth writing
|
|
160
|
+
* down carefully, because the two client paths give different answers and only one of them is
|
|
161
|
+
* the path a driver takes.
|
|
162
|
+
*
|
|
163
|
+
* Measured on MySQL 8.4.11 in `STRICT_TRANS_TABLES`, through mysql2's `execute()`, which is the
|
|
164
|
+
* binary prepared path drizzle uses:
|
|
165
|
+
*
|
|
166
|
+
* float, double all three refused, `Out of range value`
|
|
167
|
+
* decimal(10,2) all three STORED AS 0.00, silently, `SHOW WARNINGS` empty
|
|
168
|
+
* int `NaN` stored as 0 silently; both infinities refused
|
|
169
|
+
* bigint `NaN` stored as the int64 minimum silently; both infinities refused
|
|
170
|
+
*
|
|
171
|
+
* A control rules out ordinary overflow as the explanation: a finite `1e308` into the same
|
|
172
|
+
* `decimal(10,2)` is refused. So on three of those five, the server takes the row and stores a
|
|
173
|
+
* number nobody sent. This comment used to say a decimal "refuses them outright", which is the
|
|
174
|
+
* *text* path's answer: through the `mysql` CLI the same value answers `Incorrect decimal value`.
|
|
175
|
+
* Both statements are true of their own path, and only one of them describes what a validator
|
|
176
|
+
* sits in front of.
|
|
177
|
+
*
|
|
178
|
+
* The flag stays `false` on all of them, so the emitted schemas refuse all three. That is
|
|
179
|
+
* deliberately not the "never be stricter than the server" rule the range work follows: the
|
|
180
|
+
* server is not accepting the value here, it is accepting the row and storing a different value,
|
|
181
|
+
* and a validator whose whole job is to say what the database will do with a write cannot call
|
|
182
|
+
* that acceptance. Nothing is lost either way, since every generator's plain number type already
|
|
183
|
+
* refuses the three.
|
|
184
|
+
*
|
|
185
|
+
* SQLite returns both infinities and silently turns `NaN` into NULL, which is real and is filed
|
|
186
|
+
* on its own: a column needs both halves of that answer or none.
|
|
164
187
|
*
|
|
165
188
|
* Gel joined on a measurement of its own rather than on being Postgres-backed: a live Gel 7.1
|
|
166
189
|
* stored `nan`, `inf` and `-inf` in both `std::float32` and `std::float64` and handed all three
|