Databases Reference
In-Depth Information
It is also possible to change the time zone directly in the URL; for example, you could add &tz=+2:00
for the Turkey time zone.
/pls/apex/f?p=115:1:0:::::&tz=+2:00
The territory is linked to the application language. When the language is derived using “session”, the
p territory parameter can be changed in the URL without having to change the application language.
There is also an API which can be used to change the territory programmatically.
This parameter also establishes the default date format, the default decimal character and group
separator, the default International standard (ISO) and local currency symbols.
In our example, we added a select list to select the territory for the application, as shown in Figure 5-
27. Changing the select list will call the APEX UTIL API as follows:
APEX UTIL.SET SESSION TERRITORY(:P1 NEW TERRITORY);
For a list of valid territories, the following select statement can be used:
select value
from v$nls valid values
where parameter='TERRITORY'
order by 1
Figure 5-27. Example of territory change
The number will then be localized based on the territory since we are using the number format
FML999G999G999G990D00. The format only changes the display of the number; it does not convert the
amount. To apply currency conversion, you need to get the current conversion rate, as explained earlier.
The territory can also be changed in the URL by using the P TERRITORY parameter with a valid Oracle
territory name.
/pls/apex/f?p=115:1:0:::::&p territory=AMERICA
Switching Languages
Using multiple languages in an application often means that the user can select which language he
wants to access the application in.
A simple way to allow this is to add a link in the navigation bar to switch from one language to
another. For example, let's assume that the language is derived using “session” as defined in the
globalization attributes of the shared components of the application.
Search WWH ::




Custom Search