12.07.2015 Views

Oracle SQL Developer

Oracle SQL Developer

Oracle SQL Developer

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Setting up the Globalization Support EnvironmentYou should see output similar to the following:TO_CHAR(4---------4.000,0011.2.7 Monetary Parameters<strong>Oracle</strong> enables you to define radix symbols and thousands separators by locales. Forexample, in the US, the decimal point is a dot (.), while it is a comma (,) in France.Because the amount $1,234 has different meanings in different countries, it isimportant to display the amount appropriately by locale.This topic includes the following topics:■ Currency Formats■ NLS_CURRENCY■ NLS_ISO_CURRENCY■ NLS_DUAL_CURRENCY11.2.7.1 Currency FormatsDifferent currency formats are used throughout the world. Some typical ones areshown in Table 11–4.Table 11–4CountryEstoniaCurrency Format ExamplesExample1 234,56 krGermany 1.234,56€China ¥1,234.56UK £1,234.56US $1,234.5611.2.7.2 NLS_CURRENCYNLS_CURRENCY specifies the character string returned by the L number format mask,the local currency symbol. Setting NLS_CURRENCY overrides the default settingdefined implicitly by NLS_TERRITORY. The value can be any valid currency symbolstring.Example 11–9 Displaying the Local Currency Symbol-- select and format the salary column from employeesSELECT TO_CHAR(salary, 'L099G999D99') "salary" FROM employeesWHERE salary > 11000;You should see output similar to the following:SALARY---------------------$024,000.00$017,000.00$017,000.00Working in a Global Environment 11-13

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!