3
When opening an oracle connection on C#
, I need you to .
and the ,
behave according to the rule 0.000,00
a real number. I would like to know how to change this format in the open session on OracleConnection
3
When opening an oracle connection on C#
, I need you to .
and the ,
behave according to the rule 0.000,00
a real number. I would like to know how to change this format in the open session on OracleConnection
1
According to this article in the original OS, there are several answers that can elucidate your problem: how-to-format-oraclenumber-generically
Here’s one I like:
alter session set NLS_NUMERIC_CHARACTERS='.,'
alter session set nls_date_format='YYYY-MM-DD HH24:MI:SS'
0
So it stays in format pt-BR
and this is reflected in the other settings, especially in regional use:
Windows Form: Desktop Application
System.Threading.Thread.CurrentThread.CurrentCulture = New System.Globalization.CultureInfo("pt-BR")
System.Threading.Thread.CurrentThread.CurrentUICulture = New System.Globalization.CultureInfo("pt-BR")
Web: Forms or MVC Web Apllication
<system.web>
<globalization uiCulture="pt-BR" culture="pt-BR"/>
</system.web>
With these settings it will configure your application with a regional behavior, being very important, because, you do not need to interfere in these conversions that are done automatically. I have web applications running on servers outside Brazil and this is of utmost importance.
I was able to solve the problem, just change the Oracle session
Browser other questions tagged c# oracle
You are not signed in. Login or sign up in order to post.
How are you assembling your sentence? You can put an example code?
– Leonel Sanches da Silva
Starting with the title sentence: "comma and..."? and...?
– bfavaretto
@bfavaretto It must be a dramatic pause.
– Lucas Lima
not q I run sql on various machines and each one is configured in a way, some are with padarao ingles (.) and others the separator and the port pattern(,), I already forced the program to stay in ports.
– asousajose
wanted to know c has how to change the oracle session charset
– asousajose
Not giving error number exption ora-01772
– asousajose
You’re using
OracleParameter
s in yourOracleCommand
s?– Paulo Morgado