Edit D:\app\Administrator\product\11.2.0\dbhome_1\apex\images\doc\AEAPI\apex_lang002.htm
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=us-ascii" /> <meta http-equiv="Content-Style-Type" content="text/css" /> <meta http-equiv="Content-Script-Type" content="text/javascript" /> <title>MESSAGE Function</title> <meta name="generator" content="Oracle DARB XHTML Converter (Mode = ohj/ohw) - Version 5.1" /> <meta name="date" content="2009-04-14T17:32:17Z" /> <meta name="robots" content="noarchive" /> <meta name="doctitle" content=" MESSAGE Function" /> <meta name="relnum" content="Release 3.2" /> <meta name="partnum" content="E12510-01" /> <link rel="copyright" href="../dcommon/html/cpyr.htm" title="Copyright" type="text/html" /> <link rel="stylesheet" href="../dcommon/css/blafdoc.css" title="Oracle BLAFDoc" type="text/css" /> <link rel="contents" href="toc.htm" title="Contents" type="text/html" /> <link rel="up" href="preface" title="Home" type="text/html" /> <link rel="up" href="apex_lang.htm" title="APEX_LANG" type="text/html" /> <link rel="up" href="apex_lang002.htm" title="MESSAGE Function" type="text/html" /> <link rel="prev" href="apex_lang001.htm" title="Previous" type="text/html" /> </head> <body> <p id="BREADCRUMBING"><a href="preface" title="Home">Home</a> > <a href="apex_lang.htm" title="APEX_LANG">APEX_LANG</a> > MESSAGE Function</p> <table class="simple oac_no_warn" summary="" cellspacing="0" cellpadding="0" width="100%"> <col width="86%" /> <col width="*" /> <tr valign="bottom"> <td align="left"></td> <td align="center"><a href="apex_lang001.htm"><img src="../dcommon/gifs/leftnav.gif" alt="Previous" /><br /> <span class="icon">Previous</span></a> </td> </tr> </table> <p><a id="CHDBCEAB" name="CHDBCEAB"></a></p> <hr /> <div class="refsect1"> <h1>MESSAGE <a id="sthref1101" name="sthref1101"></a>Function</h1> <p>Use this function to translate text strings (or messages) generated from PL/SQL stored procedures, functions, triggers, packaged procedures, and functions.</p> <a id="sthref1102" name="sthref1102"></a> <p class="subhead2">Syntax</p> <pre xml:space="preserve" class="oac_no_warn"> APEX_LANG.MESSAGE ( p_name IN VARCHAR2 DEFAULT NULL, p0 IN VARCHAR2 DEFAULT NULL, p1 IN VARCHAR2 DEFAULT NULL, p2 IN VARCHAR2 DEFAULT NULL, ... p9 IN VARCHAR2 DEFAULT NULL, p_lang IN VARCHAR2 DEFAULT NULL) RETURN VARCHAR2; </pre> <a id="sthref1103" name="sthref1103"></a> <p class="subhead2">Parameters</p> <p><a href="#CHDFJJJB">Table: MESSAGE Parameters</a> describes the parameters available in the <code>APEX_LANG.MESSAGE</code> function.</p> <div class="tblformal"><a id="sthref1104" name="sthref1104"></a><a id="CHDFJJJB" name="CHDFJJJB"></a> <p class="titleintable">MESSAGE Parameters</p> <table class="Formal" title="MESSAGE Parameters" summary="This table describes the parameters available in the CACHE_GET_DATE_OF_REGION_CACHE procedure." dir="ltr" border="1" width="100%" frame="hsides" rules="groups" cellpadding="3" cellspacing="0"> <col width="31%" /> <col width="*" /> <thead> <tr align="left" valign="top"> <th align="left" valign="bottom" id="r1c1-t3">Parameter</th> <th align="left" valign="bottom" id="r1c2-t3">Description</th> </tr> </thead> <tbody> <tr align="left" valign="top"> <td align="left" id="r2c1-t3" headers="r1c1-t3"> <p><code>p_name</code></p> </td> <td align="left" headers="r2c1-t3 r1c2-t3"> <p>Name of the message as defined in Shared Components > Text Messages of your application in Oracle Application Express.</p> </td> </tr> <tr align="left" valign="top"> <td align="left" id="r3c1-t3" headers="r1c1-t3"> <p><code>p_p0</code> through <code>p_p9</code></p> </td> <td align="left" headers="r3c1-t3 r1c2-t3"> <p>Dynamic substitution value: p0 corresponds to 0% in the translation string; p1 corresponds to 1% in the translation string; p2 corresponds to 2% in the translation string, and so on.</p> </td> </tr> <tr align="left" valign="top"> <td align="left" id="r4c1-t3" headers="r1c1-t3"> <p><code>p_lang</code></p> </td> <td align="left" headers="r4c1-t3 r1c2-t3"> <p>Language code for the message to be retrieved. If not specified, Oracle Application Express uses the current language for the user as defined in the Application Language Derived From attribute.</p> <p>See also: <a href="../global_primary_lang.htm">Specifying the Primary Language for an Application</a> in the <a href="../preface.htm"><span class="italic">Oracle Application Express Application Builder User's Guide</span></a>.</p> </td> </tr> </tbody> </table> <br /></div> <!-- class="tblformal" --> <a id="sthref1105" name="sthref1105"></a> <p class="subhead2">Example</p> <p>The following example assumes you have defined a message called GREETING_MSG in your application in English as Good morning%0 and in German as Guten Tag%1. The following example demonstrates how you could invoke this message from PL/SQL:</p> <pre xml:space="preserve" class="oac_no_warn"> BEGIN ---- Print the greeting -- APEX_LANG.MESSAGE('GREETING_MSG', V('APP_USER')); END; </pre> <p>How the <code>p_lang</code> attribute is defined depends on how the Application Express engine derives the Application Primary Language. For example, if you are running the application in German and the previous call is made to the <code>APEX_LANG.MESSAGE</code> API, the Application Express engine first looks for a message called <code>GREETING_MSG</code> with a <code>LANG_CODE</code> of <code>de</code>. If it does not find anything, then it will revert to the Application Primary Language attribute. If it still does not find anything, the Application Express engine looks for a message by this name with a language code of en-us.</p> <div align="center"> <div class="inftblnotealso"><br /> <table class="NoteAlso oac_no_warn" summary="" cellpadding="3" cellspacing="0"> <tbody> <tr> <td align="left"> <p class="notep1">See also:</p> <a href="../global_primary_lang.htm">Specifying the Primary Language for an Application</a> in the <a href="../preface.htm"><span class="italic">Oracle Application Express Application Builder User's Guide</span></a>.</td> </tr> </tbody> </table> <br /></div> <!-- class="inftblnotealso" --></div> </div> <!-- class="refsect1" --> <!-- Start Footer --> <div class="footer"> <table class="simple oac_no_warn" summary="" cellspacing="0" cellpadding="0" width="100%"> <col width="86%" /> <col width="*" /> <tr> <td align="left"><span class="copyrightlogo">Copyright © 2003, 2009, Oracle and/or its affiliates. All rights reserved.</span><br /> <a href="../dcommon/html/cpyr.htm"><span class="copyrightlogo">Legal Notices</span></a></td> <td align="center"><a href="apex_lang001.htm"><img src="../dcommon/gifs/leftnav.gif" alt="Previous" /><br /> <span class="icon">Previous</span></a> </td> </tr> </table> </div> <!-- class="footer" --> <table class="simple oac_no_warn" summary="" cellspacing="0" cellpadding="0" width="100%"> <col width="86%" /> <col width="*" /> <tr valign="bottom"> <td align="left"></td> <td align="center"><a href="apex_lang001.htm"><img src="../dcommon/gifs/leftnav.gif" alt="Previous" /><br /> <span class="icon">Previous</span></a> </td> </tr> </table> <table> <col width="86%" /> <col width="*" /></table> </body> </html>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de