Building a dynamic IF condition

Hi all,
Is there a way to check if a dynamically built logical expression is true or false? For example, I have two values val_1 and val_2 in a table, and a logical operator also stored in my table, how do I check ( val_1 <operator> val_2 ) at run time?
I tried to concatenate this into a string and check but it does not work. Any ideas?
Thanks,
Nithya

You can try Defining a Macro or do it by Ranges:
<b>If you want to use a Macro, Try something like this:</b>
DATA: t_t001 TYPE t001 OCCURS 0 WITH HEADER LINE.
DEFINE my_dynamic_check.
if &1 &2 &3.
write:/ 'Success'.
else.
write:/ 'Failed'.
endif.
END-OF-DEFINITION.
SELECT * FROM t001 INTO TABLE t_t001.
LOOP AT t_t001.
my_dynamic_check t_t001-bukrs eq 'US01'. "US01 can be replaced by a company code in table T001
ENDLOOP.
<b>Or if You want to use Ranges:</b>
ranges: r_datum for sy-datum.
r_datum-sign = 'I'.
r_datum-option = 'EQ'.
r_datum-low = sy-datum.
apppend r_datum.
If sy-datum in r_datum.
Endif.
Thanks, Ankur
Award if the info is useful
Message was edited by:
        ankur malhotra

Similar Messages

  • Dynamic where condition

    Hi, I'm building a procedure with 4 parameters το pass in input and I ask if it's possible to build a select inside the procedure with a dynamic where condition.
    The query with 2 conditions is the following:
    SELECT count(incident_number) FROM cs.cs_incidents_all_b
    1st condition
    WHERE (TO_DATE(incident_attribute_6,'dd-mm-yyyy hh24:mi') BETWEEN TO_DATE(p_create_date_ll,'dd-mm-yyyy hh24:mi') AND TO_DATE(p_create_date_ul,'dd-mm-yyyy hh24:mi'))
    2nd condition
    AND external_attribute_4 BETWEEN p_resolv_time_ll AND p_resolv_time_ul;
    The first condition has to be always valid, but the second one, depending on the parameters has to be satisfied or not.
    The first 2 parameters (p_create_date_ll and p_create_date_ul) are always written as a string (so the first condition always works).
    The second pair of paramenters (p_resolv_time_ll and p_resolv_time_ul) can be written as numbers (from a form), or written both as '*'
    So, If the parameters p_resolv_time_ll and p_resolv_time_ul are numbers, I should retrieve a small set of data (all the 2 where condition have to work),
    while if they are both '*' ONLY the first condition has to work. Practically, in this last case the 2nd condition is how it was commented.
    Is it possible to build something that satisfy my request ?
    Thanks in advance
    Alex

    Yes I know....
    If I use an IF THEN ELSE statement I can write 2 different queries with 2 different where conditions....but I want to avoid this solution because I have 4 pair of these parameters which can assume differents values and depending on their values I have to use different where conditions
    If I use an IF THEN ELSE statement, this means to write 16 different queries....
    I already used DECODE or CASE but they not satisfy my request....
    Anybody has others ideas ?
    Thanks

  • Single quote in dynamic where condition

    BAPI_STUDENT_IDENTIFIC_ADD has a field called IDENTIFICATIONNUMBER.  This field is later used in a dynamic where condition and causes a short dump when it contains a single quote.  I will change the program that calls the BAPI to check for single quotes, but is there anything else I need to check for to ensure a correct where condition?
    Thanks,
    Dan

    Hi Dan,
    The best way to ensure correctness of syntax of a dynamic where condition is:
    Run the program in debugging mode, Get the Query that is generated dynamically and write it to some other ABAP program and perform syntax check.
    This will help you to remove all the syntax errors.
    Regards,
    Darshil

  • How to  build a dynamic control  in 'as' file

    example :
    I want to build a dynamic CheckBox in as file (in
    flex2.0),who can help me! thanks

    thanks,i'm a chinese.I'm not be good at English.
    Now the problem have be settled.
    非常感谢你!

  • Dynamic select query with dynamic where condition

    Hi all,
    I want to use the dynamic select query with dynamic where condition. For that I used the below code but I am getting dump when using this code.
    Please advice, if there is any other way to achieve this requirement.
    Thanks,
    Sanket Sethi
    Code***************
    PARAMETERS: p_tabnam      TYPE tabname,
                p_selfl1      TYPE edpline,
                p_value       TYPE edpline,
                p_where1      TYPE edpline .
    DATA: lt_where    TYPE TABLE OF edpline,
          lt_sel_list TYPE TABLE OF edpline,
          l_wa_name   TYPE string,
          ls_where    TYPE edpline,
          l_having    TYPE string,
          dref        TYPE REF TO data,
          itab_type   TYPE REF TO cl_abap_tabledescr,
          struct_type TYPE REF TO cl_abap_structdescr,
          elem_type   TYPE REF TO cl_abap_elemdescr,
          comp_tab    TYPE cl_abap_structdescr=>component_table,
          comp_fld    TYPE cl_abap_structdescr=>component.
    TYPES: f_count TYPE i.
    FIELD-SYMBOLS : <lt_outtab> TYPE ANY TABLE,
    *                <ls_outtab> TYPE ANY,
                    <l_fld> TYPE ANY.
    struct_type ?= cl_abap_typedescr=>describe_by_name( p_tabnam ).
    elem_type   ?= cl_abap_elemdescr=>describe_by_name( 'F_COUNT' ).
    comp_tab = struct_type->get_components( ).
    comp_fld-name = 'F_COUNT'.
    comp_fld-type = elem_type.
    APPEND comp_fld TO comp_tab.
    struct_type = cl_abap_structdescr=>create( comp_tab ).
    itab_type   = cl_abap_tabledescr=>create( struct_type ).
    l_wa_name = 'l_WA'.
    CREATE DATA dref TYPE HANDLE itab_type.
    ASSIGN dref->* TO <lt_outtab>.
    *CREATE DATA dref TYPE HANDLE struct_type.
    *ASSIGN dref->* TO <ls_outtab>.
    * Creation of the selection fields
    APPEND p_selfl1 TO lt_sel_list.
    APPEND 'COUNT(*) AS F_COUNT' TO lt_sel_list.
    ** Creation of the "where" clause
    *CONCATENATE p_selfl1 '= '' p_value ''.'
    *            INTO ls_where
    *            SEPARATED BY space.
    *APPEND ls_where TO lt_where.
    * Creation of the "where" clause
    APPEND p_where1 TO lt_where.
    * Creation of the "having" clause
    l_having = 'count(*) >= 1'.
    * THE dynamic select
    SELECT          (lt_sel_list)
           FROM     (p_tabnam)
           INTO CORRESPONDING FIELDS OF TABLE <lt_outtab>.
    *       WHERE    (lt_where).

    Hi Sanket,
    The above given logic of mine works for you, put the code in the If condition and try-
    just like below:
    IF NOT P_EBELN IS INITIAL.
    lt_where = '& = ''&'' '.
    REPLACE '&' WITH p_ebeln INTO lt_where.
    REPLACE '&' WITH field_value INTO lt_where.
    SELECT (lt_sel_list) INTO CORRESPONDING FIELDS OF TABLE <lt_outtab>
    FROM (p_tabnam)
    WHERE (lt_where).
    ENDIF.
    thanks\
    Mahesh

  • Building OutlineFields dynamically

    Hi all,
    I need to build dynamically an OutlineField :
    Example : I have an Array of a class which contains an Array of
    TextData which I convert in an array of a class named "LineClass"
    inheriting of the DisplayNode class. What I want to do is to build an
    Array of OutlineColumnDesc which can map all attributes names of the
    class "LineClass". Then I could assign dynamically this Array to my
    OutlineField with the SetColumnList method. But the attribute "Name" of
    the OutlineColumnDesc class is read-only !
    Does anyone have ideas or experience about building OutlineFields
    dynamically ?
    Thanks.
    - Manuel -
    Manuel DEVEAUX
    Fort&eacute; Developer
    Mutuelle Pr&eacute;viade
    Nancy, FRANCE
    E-Mail : [email protected]
    -----------------------------------------

    Hi,
    Look bellow sample program
    report  ytest.
    data: lt_fieldcatalog type lvc_t_fcat.
    data: ls_fieldcatalog type lvc_s_fcat.
    field-symbols: <fs_data> type ref to data.
    field-symbols: <fs_1>.
    field-symbols: <fs_2> type any table.
    field-symbols: <fs_3> type ypoll.
    data: lt_data type ref to data.
    assign lt_data to <fs_data>.
    ls_fieldcatalog-fieldname = 'MANDT'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'POLLID'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'TEAM'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'INITIATOR'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'DESCRIPTION'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'APPROVED'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'INITIATED_DATE'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'END_DATE'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    ls_fieldcatalog-fieldname = 'WINNER'.
    ls_fieldcatalog-tabname   = 'LT_TAB'.
    append ls_fieldcatalog to lt_fieldcatalog.
    call method cl_alv_table_create=>create_dynamic_table
      exporting
        it_fieldcatalog           = lt_fieldcatalog
      importing
        ep_table                  = <fs_data>
      exceptions
        generate_subpool_dir_full = 1
        others                    = 2
    if sy-subrc <> 0.
    endif.
    assign <fs_data>->* to <fs_1>.
    assign <fs_1> to <fs_2>.
    loop at <fs_2> assigning <fs_3>.
      write: <fs_3>-pollid.
    endloop.
    Regards
    Gaurav

  • Dynamic IF condition

    Hi Forum!
    I want to know if it's possible to build a dynamic logical expression for IF or CASE instructions and get it evaluated.
    For example:
    data: LogExp type string.
    LogExp = 'Sy-subrc eq 0'.
    IF (LogExp).
    Endif.
    Or
    data: Var type string,
          LogExp type i.
    LogExp1 = 0.
    LogExp2 = 4.
    Var = 'Sy-subrc'.
    Case (Var).
      When (LogExp1).
      When (LogExp2).
      When others.
    Endcase.
    Thanks in advance.
    John.

    Hi John,
    in general your idea of dynamic logical expression is not possible in ABAP.
    But you can use the operator IN in combination with range tables. You have define all variables in your statement. Empty range tables will be treated as true.
    See this example:
    data lt_r_subrc type range of sy-subrc.
    data ls_r_subrc like line of lt_r_subrc.
    ls_r_subrc-sign = 'I'.
    ls_r_subrc-option = 'EQ'.
    ls_r_subrc-low  = 0.
    insert ls_r_subrc into table lt_r_subrc.
    if sy-subrc in lt_r_subrc.
    " do something
    endif.
    Just modify the range tables for different conditons.
    Regards,
    Axel

  • Setting the Member & data build level dynamically

    Hello, I have got a situation where i need to set the Member & data build level dynamically based on the member. The option "Build Multidimensional down to here"(OLAPMetaoutline Menu)can be used,But when we use this option i could not perform my task as i need set the Build level dynamically based on the member level.I have to set the level dynamically for the following instance.Suppose My time dimension hierarchy is as follows: BY Year BY Quarter By Month If the year is say 1995,then quarter level & month level data is not required. If the year is say 1998,then quarter level & month level data is required. Could anyone provide a solution for dynamically setting the Member & data build level? Thanks,Sathyan

    Hi CTS,
    Thanks for ur repply,
    My source side i am having BANK_BRANCH_STATUS table has BRANCH_CODE and EOC_STATUS(possible values for this column is 'N','T','F','E' & 'B').
    The source table from which data has to tranform will be having BRANCH_CODE.
    i made odiwaitfordata as 1st step in package ,in this step the code looks like this
    OdiWaitForData "-CONTEXT=GLOBAL" "-GLOBAL_ROWCOUNT=1" "-LSCHEMA=ORACLE_FCSAILS" "-POLLINT=1000" "-RESUME_KEY_OPERATOR==" "-SQLFILTER=EOC_STATUS='E'" "-TIMEOUT=0" "-TIMEOUT_WITH_ROWS_OK=YES" "-UNIT_ROWCOUNT=>=1" "-INCREMENT_DETECTION=NO" "-TABLE_NAME=BANK_BRANCH_STATUS" "-OBJECT_TYPE=T"
    In the procedure,
    Source command-select branch_CODE from BANK_BRANCH_STATUS WHERE EOC_STATUS='E'
    Target command- Execute scenario for batch with branchid as a parameter... how to put up this in code form....could u suggest me?
    3) flag those which are executed so you don't wait for them again --how to put up this in code form....could u suggest me?
    Please sugest me,
    Thanks,
    MNK

  • Issue with Dynamic WHERE condition in Cursor in FUNCTION.

    Hi All,
    I am facing an issue with cursor having dynamic WHERE condition in a function.
    Below is the FUNCTION:
    CREATE OR REPLACE FUNCTION EXCEPTION_MERGE(TABLE_NAME IN VARCHAR2, TAB_NAME IN VARCHAR2)
    RETURN VARCHAr2
    IS
    stmt_tabcols VARCHAR2(32767);
    v_columnname VARCHAR2(32767);
    CURSOR C1 IS
    SELECT 'A.'||A.COLUMN_NAME ||' = '|| 'B.'||B.COLUMN_NAME COLUMN_NAME
    FROM
    SELECT COLUMN_ID, COLUMN_NAME
    FROM USER_TAB_COLUMNS
    WHERE TABLE_NAME  = TABLE_NAME
    AND COLUMN_NAME NOT IN ('ERROR_TAB_ID','ERROR_LOAD_DATE')
    ) A,
    SELECT COLUMN_ID, COLUMN_NAME
    FROM USER_TAB_COLUMNS
    WHERE TABLE_NAME = TAB_NAME
    ) B
    WHERE A.COLUMN_ID = B.COLUMN_ID;
    BEGIN
    FOR TABCOL IN C1
    LOOP
        stmt_tabcols := stmt_tabcols ||TABCOL.COLUMN_NAME||',';
    END LOOP;
        stmt_tabcols := RTRIM(stmt_tabcols, ',');
        RETURN stmt_tabcols;
    END;
    SELECT EXCEPTION_MERGE('WC_W_TEST_FS','WC_W_TEST_FS_GBL') FROM DUAL;It throws, below error:
    ORA-06502 : PL/SQL : Numeric or value error : character string buffer too smallIf I REPLACE TABLE_NAME and TAB_NAME with hard coded values , it works fine. Can somebody look at the code and let me know the issue.
    Edited by: ace_friends22 on Sep 9, 2012 1:08 PM

    Etbin neatly demonstrating the value of posting code in a manner which makes it easy to read.
    It's obviously an naming/scoping issue. Faced with a join like this:
    where table_name = table_namethe engine looks for something called table_name in the current scope. It finds it, a column on USER_TAB_COLUMNS and applies it to both sides of the filter. It has no way of knowing that there is also a parameter called TABLE_NAME, because that is outside its current scope. Consequently the query will join every table in your schema regardless of what values you pass, and that's why you blow the buffer.
    Takw etbin's advice and name your parameter with a prefix:
    where table_name = p_table_nameThis isn't a column in USER_TAB_COLUMNS which will force the engine to look in the next scope up, which in your case is the function, where it will find your parameter and so generate a query for the passed values only.
    Cheers, APC
    Edited by: APC on Sep 9, 2012 8:03 AM

  • Building a dynamic Member list in HFM

    Good day,
    I want to build a dynamic memberlist in HFM by using the function HS.GetSubmissionPhase("S#scenario.P#period.A#account.C1#custom1.C2 #custom2.C3#custom3.C4#custom4.I#icp”). For some reason it does not return the correct submission phase but always 1 (one). I need to retrieve the submission phase of a specific cell (account) because it can vary from period to period, and therefore it must be dynamic. I am using version 11.1.1.2 (not patched). Is there a way to do this?
    Please assist.
    Thanks,
    Danee

    Hi Chris,
    I understand the member lists are metadata driven and might have a problem with the submission groups per phase (data):
    But according to me the function should return me the valid phase submission for a specific account at a specific point in time. I need it on a report or web form, or need to find another way to filter.
    1. Submission groups are set on the accounts
    2. Submission groups are set per submission phase per period
    3. Want to retrieve all valid accounts for a specific submission phase at a specific point in time in a report
    4. Is there another way that I can filter these accounts dynamically?
    Regards,
    Danee

  • For a READ TABLE how to build a dynamic WITH KEY condition?

    Hi All,
    I have a Z table with 6 fields. The first field is the Plant and is the key field. This field can be matched with the field from selection screen. Now I have 4 character fields which can contain various values. Now I have another field at the end of the table and this field is the one which I will need for further processing.
    Now this last field will be selected based on the data for first 5 fields.
    This Read is performed in a loop and the data for all the 4 character fields may not be present.
    Now my problem is how to build a Read statement for this table where I need to get the value of the Last field based on the values of first 5 fields?

    Hi,
        Use
    IF    you have internal table With header line then use
          REad Tablename  with key  field1 = value1   field2 = value2      field3 = value3        field4 = value4    field5 = value5.
      If sy-subrc = 0.
    endif.
    if  you have internal table WithOut header line then use
         REad Tablename into workArea  with key  field1 = value1   field2 = value2      field3 = value3        field4 = value4    field5 = value5.
      If sy-subrc = 0.
    endif.
    regards,
    Amit

  • Building a dynamic query

    I have a need to build a truly dynamic query, that would be able to take online form input and create a query that would handle data requests like, How many employees earn less than #some salary, have a masters degree, and speak chinese.  or show me all the employees in org A that are vets.
    A true ad hoc query tool. 
    the back end is oracle 11g, the database  contains about 8 or 9 tables all total there about 500 records that will be searched. we are running CF7.
    I just started kicking this around today so I am open for Ideas.  add filters in the where clause, i got that,   start with  1=1 and use conditional statements to add filters as necessary.  setting up the Select and From statements, need help there.
    Since this is a small db, I thout about, but scrapped, making a super-view to query from.
    your thoughts and suggestions would be greatly appreciated.
    thanks
    jb

    What about something like this:
    1) Determine what tables are going to be involved (visual GUI/drag & drop interface for the users?)
    2) Have a table that defines the relationship between the other tables in your database - once the table selection is made by the user, you can query this table to determine what columns you are going to join on.  Obviously this won't allow you complete customization but it would work for the scenarios you describe.
    3) Use your database system properties to retrieve the field names from your included tables
    4) Allow your users to add "filters" based on the fields retrieved in (3)
    e.g. You could use an interface to allow users to add a filter, where you display a list of fields from your tables and allow them to apply a simple filter to them - keep it simple (=, !=, >, <)
    for bonus points, you could limit the options based on the field type (checkboxes for bit fields, etc)
    sanitize the user input - find a SQL-safe reg exp script to handle any unwanted characters (I'm looking at you apostrophe).
    5) Don't try an support aggregates if you don't need to - users can load the results into excel and manipulate them to their hearts content.
    6) Build your SQL using the selections made by the user.  Import all records from your joined tables.  Use the table from (2) to determine which fields they join on.  and build your where clause using the filters the user created in steap (4).  Again, be sure anything not explicitly set by the system is sanitized prior to making its way into the SQL.
    7) Execute() your SQL inside a CF query.  Expect pretty poor performance, since most SQL databases won't optimize a query plan from a dynamic SQL evaluation.
    You could build this as a multi-step wizard in CF, but it would be pretty flashy as a jQuery/web service based application.

  • Building a dynamic dialog in Acrobat with Javascript

    I am attempting to figure out how to build dynamic dialogs within Acrobat using Javascript.
    I am attempting to write a generalized PDF page splitter.  The user selects a PDF document, and then the script analyzes the open document and determines that there are N pages in the document.  I am going to run through the document and make each page its own PDF.  Each page will be considered a certain kind of page, for example, Cover, Article, Ad, etc.  and the type of page it is will affect the naming convention I use when making the new, one-page file.  For example, let's say that pages 36, 37 and 38 are page, ad and article, respectively.  Then the names I will be using for each output file will be as follows:
    P12345Pg_036.pdf
    P12345Ad_037.pdf
    P12345Ar_038.pdf
    But there is no way for my code to actually look at a given page and decide that it is page, article, ad, or one of four cover types, etc.  So I want to build a dialog that looks something like this (assume a O is meant to be a radio button):
    Page          Pagetype
    1                  O Page      O Inner cover Front         O  Outer cover Front     O Ad           O   Article
    2             
    O Page 
    O Inner cover Front    
    O  Outer cover Front
    O Ad      
    O   Article
    3             
    O Page 
    O Inner cover Front    
    O  Outer cover Front
    O Ad      
    O   Article
    4             
    O Page 
    O Inner cover Front    
    O  Outer cover Front
    O Ad      
    O   Article
    N             
    O Page 
    O Inner cover Front    
    O  Outer cover Front
    O Ad      
    O   Article
    Beacuse each document varies in length, that means the dialog will need to be dynamic.
    I have looked at the Acrobat API and determined that defining a dialog looks something like this:
    var DialogABC = {
                                       initialize: function(dialog){},
                                       commit : function(dialog){},
                                       description:{}
    app.execDialog(DialogABC)
    What I do not know how to do is create the dialog specification on the fly.  Do I treat it as a string or is there some other way of making this happen?  How can I make a dynamic description that allows for a variable number of rows?
    Please let me know if you have any thoughts.  A good reference or example would serve just as well.
    TIA!
    John

    There are two approaches to this:
    1. Treating the dialog object as a literal object
    2. Treating it as a string
    If you treat it as a literal object you can manipulate it like any other object. Each function can be defined separately, and the items in the various arrays can be added or removed as you please.
    If you treat it as a string then you can construce that string in a dynamic way, using loops or if-conditions, as you please, and then use the eval() command to convert it to an object when done.
    Both approaches are quite complex and require a lot of scripting experience to implement correctly.

  • Help me in building menus dynamically to database

    i have the following code whic is developed normal html and .js and .css pages
    i need to deploy all these in a webserver and make the menus dynamically
    i am sending he following code plz help me
    since i am new to java and jsf, jsp i am unable to perfrom the task
    mainpage.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
         <head>
              <title></title>
         </head>
         <frameset rows="93,*" border="0" frameborder="0">
              <frame src="head.htm" name="top" scrolling="no">
                        <frameset cols="130,*" border="0" frameborder="0">
                   <frame name="navi" id="navi" src="nag.htm" scrolling="no" border="0" noresize>
                        <frame name="main" id="main" src="welcome.htm" scrolling="no">
              </frameset>
         </frameset>
    </html>
    menupage.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    <head></head>
    <body>
      <script type='text/javascript'>function Go(){return}</script>
      <script type='text/javascript' src='verticalmenu_var.js'></script>
      <script type='text/javascript' src='vermenu132_compact.js'></script>
      <noscript>Your browser does not support script</noscript>
    </body>
    </html>and two javascript files they also i am pasting plz help me out how to link up the menu with the database in JSF using the following and above said codes
    verticalmenus.js
         var NoOffFirstLineMenus=9;               // Number of main menu  items
                                  // Colorvariables:
                                  // Color variables take HTML predefined color names or "#rrggbb" strings
                                  //For transparency make colors and border color ""
         var LowBgColor="#336699";               // Background color when mouse is not over
         var HighBgColor="#009900";               // Background color when mouse is over
         var FontLowColor="#ffffff";               // Font color when mouse is not over
         var FontHighColor="#ffffff";               // Font color when mouse is over
         var BorderColor="#ffffff";               // Border color
         var BorderWidthMain=1;               // Border width main items
         var BorderWidthSub=1;               // Border width sub items
         var BorderBtwnMain=1;               // Borderwidth between elements
         var BorderBtwnSub=1;               // Borderwidth between elements sub items
         var FontFamily="arial,comic sans ms,technical";     // Font family menu items
         var FontSize=11;                    // Font size menu items
         var FontBold=1;                    // Bold menu items 1 or 0
         var FontItalic=0;                    // Italic menu items 1 or 0
         var MenuTextCentered="left";          // Item text position left, center or right
         var MenuCentered="left";               // Menu horizontal position can be: left, center, right
         var MenuVerticalCentered="top";          // Menu vertical position top, middle,bottom or static
         var ChildOverlap=0.2;               // horizontal overlap child/ parent
         var ChildVerticalOverlap=0.2;               // vertical overlap child/ parent
         var StartTop=50;                    // Menu offset x coordinate. If StartTop is between 0 and 1 StartTop is calculated as part of windowheight
         var StartLeft=0;                    // Menu offset y coordinate. If StartLeft is between 0 and 1 StartLeft is calculated as part of windowheight
         var VerCorrect=0;                    // Multiple frames y correction
         var HorCorrect=0;                    // Multiple frames x correction
         var DistFrmFrameBrdr=2;               // Distance between main menu and frame border
         var LeftPaddng=8;                    // Left padding
         var TopPaddng=2;               // Top padding. If set to -1 text is vertically centered
         var FirstLineHorizontal=0;               // Number defines to which level the menu must unfold horizontal; 0 is all vertical
         var MenuFramesVertical=1;               // Frames in cols or rows 1 or 0
         var DissapearDelay=1000;               // delay before menu folds in
         var UnfoldDelay=100;               // delay before sub unfolds     
         var TakeOverBgColor=1;               // Menu frame takes over background color subitem frame
         var FirstLineFrame="navi";               // Frame where first level appears
         var SecLineFrame="main";               // Frame where sub levels appear
         var DocTargetFrame="main";               // Frame where target documents appear
         var TargetLoc="";                    // span id for relative positioning
         var MenuWrap=1;                    // enables/ disables menu wrap 1 or 0
         var RightToLeft=0;                    // enables/ disables right to left unfold 1 or 0
         var BottomUp=0;                    // enables/ disables Bottom up unfold 1 or 0
         var UnfoldsOnClick=0;               // Level 1 unfolds onclick/ onmouseover
         var BaseHref="file:///C|/rao/projects/changedframework/WebRoot/pages";                    // BaseHref lets you specify the root directory for relative links.
                                  // The script precedes your relative links with BaseHref
                                  // For instance:
                                  // when your BaseHref= "http://www.MyDomain/" and a link in the menu is "subdir/MyFile.htm",
                                  // the script renders to: "http://www.MyDomain/subdir/MyFile.htm"
                                  // Can also be used when you use images in the textfields of the menu
                                  // "MenuX=new Array("<img src=\""+BaseHref+"MyImage\">"
                                  // For testing on your harddisk use syntax like: BaseHref="file:///C|/MyFiles/Homepage/"
         //var Arrws=[BaseHref+"/resources/tri.gif",5,10,,,,BaseHref+"/resources/trileft.gif",5,10,BaseHref+"/resources/triup.gif",10,5];
                                  // Arrow source, width and height.
                                  // If arrow images are not needed keep source ""
         var MenuUsesFrames=1;               // MenuUsesFrames is only 0 when Main menu, submenus,
                                  // document targets and script are in the same frame.
                                  // In all other cases it must be 1
         var OverFormElements=1;               // Set this to 0 when the menu does not need to cover form elements.
         var RememberStatus=0;               // RememberStatus: When set to 1, menu unfolds to the presetted menu item.
         var BuildOnDemand=1;               // 1/0 When set to 1 the sub menus are build when the parent is moused over
         var BgImgLeftOffset=5;               // Only relevant when bg image is used as rollover
         var ScaleMenu=0;                    // 1/0 When set to 0 Menu scales with browser text size setting
                                  // When set to 2 only the relevant main item stays highligthed
                                  // The preset is done by setting a variable in the head section of the target document.
                                  // <head>
                                  //     <script type="text/javascript">var SetMenu="2_2_1";</script>
                                  // </head>
                                  // 2_2_1 represents the menu item Menu2_2_1=new Array(.......
         var HooverBold=0;                    // 1 or 0
         var HooverItalic=0;                    // 1 or 0
         var HooverUnderLine=0;               // 1 or 0
         var HooverTextSize=0;               // 0=off, number is font size difference on hoover
         var HooverVariant=0;               // 1 or 0
                                  // Below some pretty useless effects, since only IE6+ supports them
                                  // I provided 3 effects: MenuSlide, MenuShadow and MenuOpacity
                                  // If you don't need MenuSlide just leave in the line var MenuSlide="";
                                  // delete the other MenuSlide statements
                                  // In general leave the MenuSlide you need in and delete the others.
                                  // Above is also valid for MenuShadow and MenuOpacity
                                  // You can also use other effects by specifying another filter for MenuShadow and MenuOpacity.
                                  // You can add more filters by concanating the strings
         var MenuSlide="";
         //var MenuSlide="progid:DXImageTransform.Microsoft.RevealTrans(duration=.5, transition=19)";
         //var MenuSlide="progid:DXImageTransform.Microsoft.GradientWipe(duration=.5, wipeStyle=1)";
         var MenuShadow="";
         //var MenuShadow="progid:DXImageTransform.Microsoft.DropShadow(color=#888888, offX=2, offY=2, positive=1)";
         //var MenuShadow="progid:DXImageTransform.Microsoft.Shadow(color=#888888, direction=135, strength=3)";
         var MenuOpacity="";
         //var MenuOpacity="progid:DXImageTransform.Microsoft.Alpha(opacity=85)";
         //function BeforeStart(){return}
         //function AfterBuild(){return}
         //function BeforeFirstOpen(){return}
         //function AfterCloseAll(){return}
    // Menu tree:
    // MenuX=new Array("ItemText","Link","background image",number of sub elements,height,width,"bgcolor","bghighcolor",
    //     "fontcolor","fonthighcolor","bordercolor","fontfamily",fontsize,fontbold,fontitalic,"textalign","statustext");
    // Color and font variables defined in the menu tree take precedence over the global variables
    // Fontsize, fontbold and fontitalic are ignored when set to -1.
    // For rollover images ItemText or background image format is:  "rollover?"+BaseHref+"Image1.jpg?"+BaseHref+"Image2.jpg"
    Menu1=new Array("DataCollection","","",6,20,120,"","","","","","",-1,-1,-1,"","");
         Menu1_1=new Array("Record Based","","",3,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_1_1=new Array("Data Entry","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_1_2=new Array("Account","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_1_3=new Array("T","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu1_2=new Array("File Based","","",3,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","Nation");
              Menu1_2_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_2_2=new Array("Senarai ATR","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_2_3=new Array("Senarai Kertas Siasat","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu1_3=new Array("Auto Upload","ATR_Eksibit_Form.htm","",4,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_3_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_3_2=new Array("Senarai ATR","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_3_3=new Array("Senarai Kompaun","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_3_4=new Array("Senarai LJKR","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu1_4=new Array("Validation Failure","Permohonan_Keluar_Eksibit_Form.htm","",3,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_4_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","Football Every Day");
              Menu1_4_2=new Array("Senarai ATR","ATR_Eksibit_Form.htm","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_4_3=new Array("Senarai Eksibit","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu1_5=new Array("Pendakwaan","Permohonan_Keluar_Eksibit_Form.htm","",3,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_5_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_5_2=new Array("Senarai ATR","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
              Menu1_5_3=new Array("Senarai LKKP","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu1_6=new Array("OKT","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu2=new Array("Statistical Analysis","","",1,20,120,"","","","","","",-1,-1,-1,"","");
         Menu2_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu3=new Array("Discovery Analysis","","",1,20,120,"","","","","","",-1,-1,-1,"","");
         Menu3_1=new Array("Carian","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu4=new Array("Case Management","","",2,20,120,"","","","","","",-1,-1,-1,"","");
         Menu4_1=new Array("Operasi","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu4_2=new Array("Pengurusan","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu5=new Array("Content Management","","",3,20,120,"","","","","","",-1,-1,-1,"","");
         Menu5_1=new Array("e-LesenNiaga","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu5_2=new Array("e-Tribunal","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu5_3=new Array("e-Aduan","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu6=new Array("Audit log","","",0,20,120,"","","","","","",-1,-1,-1,"","");
    Menu7=new Array("Administration","","",6,20,120,"","","","","","",-1,-1,-1,"","");
         Menu7_1=new Array("Akta","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu7_2=new Array("Jenis Cetak Rompak","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu7_3=new Array("Jenis Eksibit","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu7_4=new Array("Jenama","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu7_5=new Array("Karya Cetak Rompak","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
         Menu7_6=new Array("Kawasan","","",0,20,120,"#e1ffb3","#edf6d9","#404040","#0E61AE","#5eb101","",-1,0,-1,"left","");
    Menu8=new Array("Pentadbiran","","",0,20,120,"","","","","","",-1,-1,-1,"","");
    Menu9=new Array("Tukar Kata Laluan","","",0,20,120,"","","","","","",-1,-1,-1,"","");
    plz help me out in doing so and save me
    thank you

    Please view open source JSF menu
    http://myfaces.apache.org/tomahawk/jscookmenu.html

  • How do I build a dynamic business service URL in OSB 11g?

    Hello,
    I am used to using the business service endpoint URIs that we configure on the Transport tab of our business services in OSB 11.1.1.6.  We can add multiple static entries here for load balancing, and we can overwrite these with a Customization File as we migrate through DEV, TEST, PROD.  Everything's just fine there.
    I now need to start consuming RESTful services with dynamic URLs such as:
    http://host:port/customer/{customerId}
    that would result in HTTP calls to values like:
    http://host:port/customer/12345678
    and
    http://host:port/customer/55555555
    I see that I can build the URI using the Routing Options action in our proxy message flow and throw in all of those variable values at runtime.  This is working in DEV just fine.  And, effectively, I've overridden the business service endpoint URIs that we configured in the Transport.
    But now I want to:
    1) Use multiple endpoint URIs for our cluster
    2) Deploy to TEST
    What is the proper way to do this?  I would guess in the business service endpoint URIs in the customization file, but I don't know how to parameterize those.  I would also guess customization file find/replace functionality to change the host:port in my Routing Options action, but then that would still be just a single-node endpoint and not a pointer to multiple servers in our cluster.
    Can someone please advise the best way to configure these dynamic URLs at runtime while still allowing for clustered endpoints and for customization files to be applied as we promote through our environments?
    Thank you,
    Michael

    Found some old code.
    I think you need to do
    property_text = "#"^variable_text
    then you can do the following
    property_list[1][property_text]
    That seemed to work.

Maybe you are looking for