Hi,

With PG84, I have tried something like this which seem incorrect to me.

# SELECT '' AS to_number_2,  to_number('-347,58', '99G999');
 to_number_2 | to_number
-------------+-----------
             |     -3458
(1 row)

After browsing the code (numeric_to_number), I have found that number string
is processed according to the number format. Which means, when 'G' is found
in the format we have moved the number pointer to next character. This is
why the digit '7' is skipped. And while processing ',', as it is not a digit
it is ignored.

Is this expected behaviour? or a bug?

Thanks

-- 
Jeevan B Chalke
EnterpriseDB Software India Private Limited, Pune
Visit us at: www.enterprisedb.com
---
If better is possible, then good is not enough

Reply via email to