Meridianmeridian

Decimal Number (EU Format)

representation.numeric.decimal_number_eu

Number with European formatting: period as thousands separator and comma as decimal separator (e.g., 1.234,56, 999,99, -42,5). The inverse of US format where period is decimal and comma is thousands. Silent corruption risk: "1.234" is either 1234 (European thousands) or 1.234 (US decimal). Transforms to DOUBLE after swapping separators.

Domain
representation
Category
numeric
Casts to
DOUBLE
Scope
Universal

Try it

CLI
$ finetype infer -i "1.234,56"
→ representation.numeric.decimal_number_eu

DuckDB

Detect
SELECT finetype('1.234,56');
-- → 'representation.numeric.decimal_number_eu'
Cast expression
CAST(REPLACE(REPLACE({col}, '.', ''), ',', '.') AS DOUBLE)
Safe cast pipeline
-- Normalise and cast in one step
SELECT TRY_CAST(finetype_cast(my_column) AS DOUBLE) AS clean_value
FROM my_table
WHERE finetype(my_column) = 'representation.numeric.decimal_number_eu';

Struct Expansion

Expression
fractional_part: CAST((CAST(REPLACE(REPLACE({col}, '.', ''), ',', '.') AS DOUBLE) - FLOOR(CAST(REPLACE(REPLACE({col}, '.', ''), ',', '.') AS DOUBLE))) * 1000000 AS BIGINT)
integer_part: CAST(FLOOR(CAST(REPLACE(REPLACE({col}, '.', ''), ',', '.') AS DOUBLE)) AS BIGINT)

JSON Schema

finetype schema representation.numeric.decimal_number_eu
{
  "$id": "https://meridian.online/schemas/representation.numeric.decimal_number_eu",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "description": "Number with European formatting: period as thousands separator and comma as decimal separator (e.g., 1.234,56, 999,99, -42,5). The inverse of US format where period is decimal and comma is thousands. Silent corruption risk: \"1.234\" is either 1234 (European thousands) or 1.234 (US decimal). Transforms to DOUBLE after swapping separators.",
  "examples": [
    "1.234,56",
    "999,99",
    "1.000.000,00",
    "-42,5",
    "0,75",
    "12.345,678",
    "100,00",
    "-1.234,00"
  ],
  "pattern": "^-?[0-9]{1,3}(\\.[0-9]{3})*(,[0-9]+)?$|^-?[0-9]+,[0-9]+$",
  "title": "Decimal Number (EU Format)",
  "type": "string",
  "x-finetype-broad-type": "DOUBLE",
  "x-finetype-transform": "CAST(REPLACE(REPLACE({col}, '.', ''), ',', '.') AS DOUBLE)"
}

Examples

1.234,56999,991.000.000,00-42,50,7512.345,678100,00-1.234,00

Aliases

eu_decimaleuropean_numberdecimal_eu