21.6.2 Translating Messages Used in PL/SQL Procedures

Learn about how to translate messages used in PL/SQL procedures.

See Also:

APEX_LANG in Oracle APEX API Reference

21.6.2.1 About Translating Messages Used in PL/SQL Procedures

Learn about translating messages used in PL/SQL procedures.

If your application includes PL/SQL regions or PL/SQL processes or calls PL/SQL package, procedures, or functions, you may need to translate generated HTML. First, you define each message on the Translatable Messages page. Second, you use the APEX_LANG.MESSAGE API to translate the messages from PL/SQL stored procedures, functions, triggers, or packaged procedures and functions.

21.6.2.2 Defining a Translation Message

Learn about defining a translation message.

You create translatable messages on the Translate Messages page.

To define a new translation message:

  1. Navigate to the Translate Application page:
    1. On the Workspace home page, click the App Builder icon.
    2. Select an application.
    3. Click Shared Components.
    4. Under Globalization, click Text Messages.
  2. On the Translate Messages page, click Create Text Message.
  3. On Identify Text Message:
    1. Name - Enter a name to identify the message.
    2. Language - Select the language for which the message would be used.
    3. Used in JavaScript - Select On if the message is used in APEX.LANG API calls in JavaScript code.
    4. Text - Enter the text to be returned when the text message is called.

      For example, you could define the message GREETING_MSG in English as:

      Good morning %0
      

      Or, you could define the message GREETING_MSG in German as:

      Guten Tag %0
      
  4. Click Create Text Message.