By default via select or function

Hi gurus,

I have a scenario where I need to get the value of a certain table... as the name of the company...

It will serve as a default value.

a thingking to use a select statement or function for this, but do not know how I would use...

pls help

You can use this

OAMessageStyledTextBean txtCompany = (OAMessageStyledTextBean) webBean.findChildRecursive ('Company');

Thank you

Tags: Oracle Applications

Similar Questions

  • Grant permission to select the function but not executed in a PL/SQL block

    Hello.

    I know that there are only two permissions on procedures/functions - RUN and DEBUG.

    But I want to grant EXECUTE permissions for a user so that the user can Select the function to double or to any other request, but not to run(to prevent the user to trigger the update of LMD - insertion, etc.) inside a BEGIN-END block.

    I know that we can revoke access to tables etc. But that access has to give. The user must be able to perform the DML operation, but just not through a function.

    Can someone please help?

    I know that there are only two permissions on procedures/functions - RUN and DEBUG.

    Fix - so give one or both of those who depend on your use case.

    
    But I want to grant the EXECUTE permission to a user in such a way that the user can select the function using dual or any other query but not execute( to prevent the user from firing DMLs - Insert, update etc) inside any BEGIN-END block.
     
    

    You already know that there is NO "select" privileges for functions. a query such as "select the function of double" RUNS the function. That's all what you can do with the functions is execute them.

    I know that we can revoke access to tables etc. But that access has to be given. The user should be able to do perform DML operation, but just not through a function.
    

    Then revoke execute on the service. Then the user cannot run the service either directly or in the context of a dml statement.

  • By default the selected value SelectManyListBox

    JDev 11.1.1.6.0

    I have a requirement to display default values selected in selectManyListBox.

    Like, there are two lists:

    public list < SelectItem > getList() {}
    list = new ArrayList < SelectItem > ();
    List.Add (new SelectItem("1","HDFC"));
    List.Add (new SelectItem("3","ICICI"));
    List.Add (new SelectItem("4","Citi"));
    List.Add (new SelectItem("14","SBI"));
    List.Add (new SelectItem("33","Others"));
    back list;
    }

    public list < SelectItem > getSelectedList() {}

    selectedList = new ArrayList < SelectItem > ();

    selectedList.add (new SelectItem("3","ICICI"));

    selectedList.add (new SelectItem("4","Citi"));

    Return selectedList;

    }

    When the page loads, I want to than selectedList default values and the remaining values (not selected) available for selection list.

    Hello Sahar,

    What is the scope of your beans?

    You need link for your selectManyChoice component value to a list of selectItem in your beans. Then, at the bean of the constructor, you can add the values you need to the list. Thus, when the page first loads, it creates an instance of your beans and in the constructor, the list is populated with the preset values.

    Concerning

  • How to change the default "/" shortcut (select none in the shade of color) to something different? Where can I find this in keyboard shortcuts?

    How to change the default "/" shortcut (select 'none' in the shade of color) to something different? Where can I find this in keyboard shortcuts?

    Any ideas?

    In the Tools menu:

    "Apply no color."

  • In the date picker, how can I default to select * dates if the user has...

    In the date picker, how can I default to select * dates if the user does not select a date.
    Thank you
    Doug

    Doug,

    Now lets say l want everything
    

    Could you post some sample data and the output you want to get... ? It would be very easy to understand the requirements...

    When you mean everything, I guess you need all possible dates between date1 and date2.

    You can use... (to asktom.oracle.com).

      1  select to_date('12-jan-2009','DD-MON-YYYY') + rownum -1
      2    from ALL_OBJECTS
      3    where rownum <= (to_date('20-jan-2009','dd-mon-yyyy') -
      4*                     to_date('12-jan-2009','DD-MON-YYYY') +1 )
    sql> /
    
    TO_DATE('
    ---------
    12-JAN-09
    13-JAN-09
    14-JAN-09
    15-JAN-09
    16-JAN-09
    17-JAN-09
    18-JAN-09
    19-JAN-09
    20-JAN-09
    
    9 rows selected.
    
    For your case, since you have date1 and date2...
    
    select to_date(:p12_date1,'DD-MON-YYYY') + rownum -1
      from ALL_OBJECTS
      where rownum <= (to_date(:p12_date2,'dd-mon-yyyy') -
                        to_date(:p12_date1,'DD-MON-YYYY') +1 )
    

    Should work... in my opinion... Have not tested the other by their Summit.

    Is that what you're looking for... ?? If no, please give details...

    Thank you
    Rajesh.

  • Pass default to select list

    Hi all


    Select City_name in ABC.

    I want to spend this Quary in default value of the select list.

    How can I do that.


    Thank you

    If you open any item definition, you can find a section called default. Choose the type of organ Function, PLSQL and add an anonymous PLSQL block that returns the value

    For example.

    DECLARE
      lc_value ;
    BEGIN
      Select  INTO  lc_value
      from  where <>;
    
      return lc_value;
    END;
  • Access a package Via Select Global variable

    Hi all

    I want to access a global variable of the overall package variable IE via a select query. Is it possible or not possible. Please share some entries on this.

    Thank you

    Just to clarify that you can reference the global variable if your SQL is itself in PLSQL. It will be linked to.

    CREATE OR REPLACE PACKAGE p1
    AS
      my_global NUMBER := 1;
      --
      FUNCTION f_get_my_global
      RETURN NUMBER;
      --
      PROCEDURE p_do_something;
      --
    END;
    /
    
    CREATE OR REPLACE PACKAGE BODY p1
    AS
      --
      FUNCTION f_get_my_global
      RETURN NUMBER
      AS
      BEGIN
         RETURN my_global;
      END;
      --
      PROCEDURE p_do_something
      AS
        l1 NUMBER;
      BEGIN
        SELECT /*+ find_me */
               my_global
        INTO   l1
        FROM   DUAL;
      END;
      --
    END;
    /
    
    SQL>  exec p1.p_do_something;
    
    PL/SQL procedure successfully completed.
    
    SQL> select sql_text from v$sql where sql_text like '%find_me%';
    
    SQL_TEXT
    --------------------------------------------------------------------------------
    SELECT /*+ find_me */ :B1 FROM DUAL
    
    SQL>
    
  • Select the function

    A select function runs all code for values of entry for both entries, even if I have the wiring a constant FALSE to the Selector? (Can you avoid business structures with selection function?)

    Yes. And no. LabVIEW is a language of stream, not a procedural language. Thus, a function will not run until all entries that are wired have given on these threads. That said, the Select function has no code in itself, if your question doesn't make much sense. Whatever the code is on the block diagram to generate data on the wire that is connected to the real part still needs to run as the Select function needs these data as the input selection is true or false.

    The Select function is not designed to avoid and replace structures of the case. If so, there is no need of a box structure. It has its use, like the structure of the case. If you try to avoid the computation of something then it seems to me that you really want a case structure.

  • Default keys to material function on spectrum XT touchsmart 15

    Hello

    I often use the keys function within software development IDEs like Visual Studio client. However on my touchsmart spectrum XT 15 material function default function key function. For example when I press F5 on ay other laptop computer running the program I'm developing; However on my spectrum XT he turns off the lights on the keyboard.

    I have to press the fn key first to make the funtion key as it should. Other laptops, you press this button first to get the function of equipment.

    Is it possible to reverse this function so I don't have to remember to press it all first all the time?

    Thank you

    Hello

    You can ignore the Fn key as mantioned in the following link:

    http://support.HP.com/us-en/document/c02035108

    Kind regards.

  • The default printer selection limited

    I would like to power limit/prevent our users to select a printer as the default.

    If by 'our users', you are referring to the members of a domain, your question is better suited for the Microsoft Technet forums.

  • Using the values of default setting with the functions or procedures?

    If you have a procedure or a function that has DEFAULT values reported for some parameters How do you call this function or procedure when you want to use some of the default values? I tried...

    myProcedure(202,,);
    myProcedure (202, ",");
    myProcedure(202,null,null);
    myProcedure (job_id = 202);
    myProcedure (job_id = > 202);

    None of the above worked.

    PROCEDURE add_job (job_id IN jobs.job_id%TYPE
    job_loc IN jobs.job_location%TYPE DEFAULT 145
    mgr_id IN DEFAULT jobs.mgr_id%TYPE 30
    );

    Thank you.

    EDIT: I will say that it is a simplified example. Imagine you please a parameter list much more great and perhaps half having DEFAULT values. Thank you.

    PROCEDURE myProcedure (job_id IN jobs.job_id%TYPE
    job_loc IN jobs.job_location%TYPE DEFAULT 145
    mgr_id IN DEFAULT jobs.mgr_id%TYPE 30
    init_id IN jobs.init_id%TYPE
    sal_id IN jobs.sal_id%TYPE 100 by DEFAULT
    , clock_id IN DEFAULT jobs.clock_id%TYPE "A".
    shift_id IN jobs.shift_id%TYPE
    , lot_id IN DEFAULT jobs.lot_id%TYPE «BACK»
    );

    Published by: davejjj on March 20, 2013 16:47

    Hi davejjj,

    Here is an example of calling your myprocedure. This example uses default values for sal_id, clock_id, lot_id

    declare
      procedure myprocedure (
        job_id     in jobs.job_id%type,
        job_loc    in jobs.job_location%type default 145,
        mgr_id     in jobs.mgr_id%type default 30,
        init_id    in jobs.init_id%type,
        sal_id     in jobs.sal_id%type default 100,
        clock_id   in jobs.clock_id%type default 'A',
        shift_id   in jobs.shift_id%type,
        lot_id     in jobs.lot_id%type default 'BACK'
      );
    begin
      myprocedure (job_id     => your_job_id,
                   job_loc    => your_job_loc,
                   mgr_id     => your_mgr_id,
                   init_id    => null,
                   shift_id   => your_shift_id
                  );
    end;
    /
    

    This, however, will NOT WORK, because myprocedure doesn't have a default value declared for init_id

    begin
      myprocedure (job_id     => your_job_id,
                   job_loc    => your_job_loc,
                   mgr_id     => your_mgr_id,
                   shift_id   => your_shift_id
                  );
    end;
    /
    

    Concerning
    Peter

  • Calll to a procedure via the Decode function

    Hello

    I just want to know if it is possible to call precudure as below,

    Select inv.invoice_id, decode ('AS_AP_INV_APPROVESTATUS (inv.invoice_id)', ' n,+)
    Decode(AMOUNT_PAID,,'Enterd',0,'Entered')) stat
    from apps. AP_INVOICES_ALL inv

    This property returns only the value (null).

    Is a syntax error or is at - it another way to call it?

    Thank you

    First of all, it must be a function, not a procedure ;-)

    Secondly, you should not put it inside quotes - you do not claim the function, you're simply decode if your string is equal to 'n'.

    select inv.invoice_id, decode(AS_AP_INV_APPROVESTATUS(inv.invoice_id),'N',
    decode(AMOUNT_PAID,null,'Enterd',0,'Entered')) stat
    from apps.AP_INVOICES_ALL inv
    

    This assumes that AS_AP_INV_APPROVESTATUS is a function that returns a string value.

  • No default line selected in af:table

    Hello

    I don't need no line selected default differance on the rendering of the original of an af:table with a unique selection enabled.
    The reason is that the af: table has an associated selection listener. If a line is selected by default, the user cannot select the line again to perform an action on this subject.
    I don't want to.

    Is there a way to make a table with no rows selected by default?

    having an affair at the table in the bean managed... with getter and Setter... and in the Get accessor, make it like

    RicheTableau tableBidding;

    public richeTableau getTableBinding() {}
    If (tableBinding! = null) {}
    tableBinding.getSelectedRowKeys () .clear ();
    }
    tableBinding return;
    }

  • by default in select multi

    This question is about the thread of Jarola to

    Re: select the default value for a list of all

    Here Jarola says:
    My example is here on select multi.
    http://Apex.Oracle.com/pls/OTN/f?p=40323:25


    In a multi select, if default result is displayed for all options, then how a user can know that these results are for all options.
    We have ALL the top of the multiple selection. This SETis entered in the field "null value" of the item.

    Can I just highlight (only when the user does not select another option) to show the user that this is the default option.

    Try to add something like the code below in the footer

    
    

    CITY

  • By default, all selection list

    I have a selection list that has
    1 (Critical) 2 (Major) 3 (Significant Error) 4 (Minor) 5 (Suggestion) 6 (Enchancement)
    as possible return values. I want to understand (All) of 0 by default, how can I work that my request? Currently, I have something like
    and issue_severity.issue_severity_id = :CBO_P21_SEVERITY
    in the WHERE clause, which works very well for values of 1 to 6 above. However, users would be able to raise questions of all severities (basically don't filter not not results based on gravity at all), and this is where I am stuck. I tried implementing a decoding as
     and decode(:CBO_P21_SEVERITY, 0, issue_severity.issue_severity_id in (1,2,3,4,5,6), issue_severity.issue_severity_id = :CBO_P21_SEVERITY)
    or an instruction box as
    case :CBO_P21_SEVERITY when 0 issue_severity.issue_severity_id in (1,2,3,4,5,6) else issue_severity.issue_severity_id = :CBO_P21_SEVERITY
    but neither works. I thought to do some sort of calculation, but I don't know even where to start with this.

    Hello

    OK your column is the number that's why error. Try

    and (
    (issue_severity.issue_severity_id = DECODE(NVL(:CBO_P21_SEVERITY,'%'||'null%'),'%'||'null%',0,:CBO_P21_SEVERITY)
     OR (NVL(:CBO_P21_SEVERITY,'%'||'null%') = '%'||'null%')
    )
    

    BR, Jari

  • Maybe you are looking for