final class Magnitudes
Restricted visibility: declared "@visibility SqlSemantics\Platform\MySql". Code outside that scope must not name this declaration.

Measures the operands whose size the server checks while it parses a server administration statement.

Rule: MYSQL-SERVER-MAGNITUDE-001. The length of a string operand is its byte count: the decoded bytes of a quoted string, half the hexadecimal digits rounded up, an eighth of the bits rounded up. A number at a position that is not an expression is converted as the server converts it: a hexadecimal literal by its digits, clamped to 2^63-1 as strtoll clamps it, any other number by the decimal digits it starts with (my_strtoll10 stops at a point or an exponent). The format identifier of an XA transaction identifier is refused above 2^63-1 from 5.7 on (format_id_overflow_detected in the xid action); 5.6 takes any. The comparison is exact on the digit strings, without a PHP number. At a position the grammar reads through dec_num_error a decimal or floating number is FractionalNumber (ER_ONLY_INTEGERS_ALLOWED). Terminates: one pass over the digits. Source: https://dev.mysql.com/doc/refman/8.4/en/number-literals.html, https://dev.mysql.com/doc/refman/8.4/en/hexadecimal-literals.html. Status: Implemented.

Constants§

public const LARGEST = '9223372036854775807'

The largest signed 64-bit integer, the value strtoll gives a larger hexadecimal number.

Methods§

public function decimal(string $hexadecimal): string

Converts hexadecimal digits into decimal digits exactly.

Parameters

$hexadecimalstring

Returns

string
Test cases 1
Called from 1
Calls 6

Test cases 6§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 6

Relations§

Instantiated in 12
Method calls 20