Skip to content

Decimal results incorrect depending on locale #753

@gv-collibris

Description

@gv-collibris

Environment

  • Python: 3.6.3
  • pyodbc: 4.0.30
  • OS: WSL, Windows 10, Debian 10
  • DB: SQL Server
  • driver: ODBC Driver 17 for SQL Server

Issue

Numbers (e.g. 3656.880000) from the database are turned to different numbers in Python, depending on the locale, e.g. 3656.88 for an English locale, and 3656880000 for a French one.

Expected behavior

I would expect to always obtain the correct number in the Python code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions