Change Build Status From PL/SQL

Apex 3.2
Please see my previous thread
Change Build Status From PL/SQL
We tried this code
CREATE OR REPLACE procedure APEX_030200.pr_sup_unfreeze_apex
as
begin
  for l_app in (select id
                      ,security_group_id
                from APEX_030200.wwv_flows
  loop
    wwv_flow_api.set_security_group_id(l_app.security_group_id);
    wwv_flow_api.set_flow_status (p_flow_id     => l_app.id
                                 ,p_flow_status => 'AVAILABLE'
  end loop;
  commit;
exception when others then
  dbms_output.put_line (sqlcode);
  dbms_output.put_line (substr(sqlerrm,1,250));
  dbms_output.put_line (substr(sqlerrm,250,250));
  rollback;
  raise;
end;but recieved error
BEGIN APEX_030200.pr_sup_freeze_apex; END;
Error at line 1
ORA-20001: Package variable g_security_group_id must be set.
ORA-06512: at "APEX_030200.PR_SUP_FREEZE_APEX", line 51
ORA-06512: at line 1
Any ideas ?
If I just run
select id,security_group_id
from APEX_030200.wwv_flows
ID SECURITY_GROUP_ID
4000 10
4050 10
4155 10
4300 10
4350 10
4400 10
4411 10
4500 10
4550 10
4700 10
125 1.07701203277056E15
1000 1.08971536719791E15
1010 1.08971536719791E15
114 1.41432144152464E15
123 1.43440509319107E15
160 2.25192481868561E15
190 2.41432896355852E15
100 3.93632559648557E15
103 3.93632559648557E15
130 5.9543257997941E15
140 5.95501879180405E15
Edited by: Gus C on Nov 8, 2012 5:43 AM
Edited by: Gus C on Nov 8, 2012 5:50 AM

Hi Gus,
as Rod already mentioned, wwv_flow_api.set_flow_status would be the way to go. It's no officially documented or supported API but it will do what you want. Just be prepared that it might be removed in the future. The API is defined as following:
procedure set_flow_status (
    p_flow_id                   in number,
    p_flow_status               in varchar2,
    p_flow_status_message       in varchar2 default null,
    p_restrict_to_user_list     in varchar2 default null )Example code to make all applications unavailable (has to be executed as APEX_040200).
begin
    for l_app in ( select id,
                          security_group_id
                     from wwv_flows )
    loop
        wwv_flow_api.set_security_group_id(l_app.security_group_id);
        wwv_flow_api.set_flow_status (
            p_flow_id     => l_app.id,
            p_flow_status => 'UNAVAILABLE' );
    end loop;
    commit;
end;Regards
Patrick
My Blog: http://www.inside-oracle-apex.com
APEX Plug-Ins: http://apex.oracle.com/plugins
Twitter: http://www.twitter.com/patrickwolf

Similar Messages

  • Is it possible to change the status from Bid Rejected to Bid submitted?

    Hi there.
    We are working in SRM 4.0.
    One user rejected a bid, but it was a mistake. Is it possible to change the status from Bid Rejected to Bid submitted?
    We would like to modify the status from Bid Rejected to Bid submitted or Awaiting Approval to Bid submitted in order to solve errors.
    Thanks and regards.
    Raúl Moncada.

    Hi ,
    Use Function Module : BBP_PD_BID_STATUS_CHANGE
    Supply Activity = 'QOSU' .
    Regards,
    Sachin S M

  • Cannot Change Item Status from Active to Inactive

    Dear All
    Cannot Change Item Status from Active to Inactive on Item master screen. can any one provide the steps.
    Best Regards
    Arifuddin

    Check on below link under "Defining Item Status Codes"
    http://docs.oracle.com/cd/E18727_01/doc.121/e13450/T291651T291798.htm#I_t_ditstatus
    thanks

  • Building report from PL/SQL cursor

    Hello,
    is there any way to build APEX report using just PL/SQL cursor?
    I don't have grant to SELECT from views or tables, but I can use some functions returning row types and cursors. I know I can use them to build table from scratch with htp.p etc., but it’s not very nice. I want to do it using APEX reporting with filtering and pagination functionality.
    Is it possible?
    Regards,
    Przemek

    Apologies for the delay, I was out of the office.
    Below is a package serving as the basis for creating a view based on a pipelined function. The package is just a skeleton and will not compile in its current form, you will need to go through it filling in the blanks as described by the comments.
    If you want some control over what rows are returned by the view from a larger result set, use the set_parameters function in the WHERE clause, E.G.:
    select * from really_big_complicated_slow_view where 1 = view_pkg.set_parameters(something_that_reduces_the_view_result_set_size);
    Or, a more concrete example:
    select result_text from view_to_convert_to_csv where 1 = view_pkg.set_parameters(pi_table => 'my_table', pi_where = 'whatever');
    In the spirit of full disclosure, I got the idea for using the "set_parameters" function in the view WHERE clause from a post or blog somewhere a couple of years ago but have lost track of who actually deserves the credit for the good idea.
    -Tom
    create or replace package demo_vw as
    -- Package to serve as the basis for a view based on a function
    -- Customize this record so that it represents a row from this view...
    type row_type is record (
    -- record fields here
    type table_type is table of row_type;
    -- This function is used in the DDL to define the view, for example:
    -- create or replace view my_view (col1, col2, ..., colN) as
    -- select * from table(my_view_vw.get_view);
    function get_view
    return table_type
    pipelined;
    -- Customize this function header to accept the parameters for this view, if
    -- any. If this view does not require any parameters, the set_parameters
    -- function may be deleted.
    -- This function should always return 1 and is called as follows
    -- select <whatever>
    -- from my_view
    -- where 1 = my_view_vw.set_parameters(p1, p2, p3, ..., pN);
    function set_parameters (pi_whatever1 in whatever,
    pi_whateverN in whatever)
    return number;
    end demo_vw;
    show error package demo_vw
    create or replace package body demo_vw as
    -- Customize this list of private global variables to match the parameters
    -- required by the view. These variables are set, reset, and validated by
    -- set_parameters, reset_parameters, and valid_parameters respectively...
    g_var1 whatever;
    g_varN whatever;
    function set_parameters (pi_whatever1 in whatever,
    pi_whateverN in whatever)
    return number
    is
    -- Customize this function header to accept the parameters for this view, if
    -- any. If this view does not require any parameters, the set_parameters
    -- function may be deleted.
    -- This function should always return 1 and is called as follows
    -- select col1, col2, ..., colN
    -- from my_view
    -- where 1 = my_view_vw.set_parameters(p1, p2, p3, ..., pN);
    begin
    g_var1 := pi_whatever1;
    g_varN := pi_whateverN;
    return 1;
    end set_parameters;
    function valid_parameters
    return boolean
    is
    -- Customize...
    -- Assumes that set_parameters has been called to set the value of the view
    -- parameters.
    l_valid boolean := true;
    begin
    return l_valid;
    end valid_parameters;
    procedure reset_parameters
    is
    -- Customize...
    -- This is called at the end of the get_view function to reset the view
    -- parameters for the next caller.
    begin
    g_var1 := null;
    g_varN := null;
    end reset_parameters;
    function get_view
    return table_type
    pipelined
    is
    -- build and return each row for the view...
    l_row row_type;
    begin
    if valid_parameters then
    -- do your process to populate the l_row variable here...
    pipe row (l_row);
    end if;
    reset_parameters;
    exception
    when others then
    reset_parameters;
    raise;
    end get_view;
    end demo_vw;
    show error package body demo_vw
    create or replace view demo
    as
    select * from table(demo_vw.get_view);

  • Sharepoint Designer - Two step List Workflow task item is not changing the status from not started to Complete

    Hi 
    Using SPD i am creating list workflow.
    Scenario: Employee submits a request . Task assign to manager. Manager can either approve/ reject. If approve then change the state column to "done". If rejected the state column to "Rejected".
    Problem is "Assign a to do item" is assigning the task to manager. But after manager approves the status in the task list not changed to "Completed". Still it is showing "Not started". I dont want to manually complete the task.
    Please help me for automatic process. 
    What i should do to change the status to "Complete" automatically after manager approval
    Regards
    Jhanani
    Janani.R

    Hi Janani,
    From your description, you would like to create an approval workflow for a list. When an employee submit a request to the list, an approval task should be assigned to manager, then manager could approve or reject the request. From the request list,
    we should be able to see the Approval task’s status.
    Not understand the reason of designing the workflow to two steps, an approval action should be enough from my understanding. For producing, I create a list named Request list, then customize it in InfoPath form to add a Request field for stating request
    content. Then add a workflow to list named Approval task, add the action of Start an approval process with administrator and make the workflow automatically start when item is added.
    The image below shows the status of Adding items, Approving and Rejecting. Please check if it could meet your requirement.
    Regards,
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected] .
    Rebecca Tu
    TechNet Community Support

  • Change Report Status from "completed / passed" to "Completed"?

    With Captivate 5, is it possible to change the Report Status from "completed / passed" to "Completed"? The "completed / passed" given is causing issues with my LMS thus need "Completed" only. Is this possible with version 5 or even version 6?
    Thank you in advance for any help!

    Hi There,
    Thank you for reaching Adobe Community.
    You can select the below settings from Edit > Preferences >  Quiz > Reporting panel. You can change the Status representation to Incomplete > Complete.
    Here is the screen shot frm ScormCloud LMS:
    Thanks!

  • Change work status from Excel interfase directly

    Hi,
    Anyone knows if there is a way to change the work status directly from the Excel interfase? I mean, with vba code or some function instead of using the web interfase?
    Thanks.
    Regards

    Hi.
    I have the same need in MS. I would like to change work status directly from Excel but don´t know how to do it.
    Can you please clarify about the program UJW_WS_TEST? I don´t know what is this (it probably is different in BPC MS 7.5?)
    Thanks.

  • Programmatically Changing Build Specifications from command line

    I use a batch file that calls a VI to build several LV projects.  I found the article http://zone.ni.com/devzone/cda/epd/p/id/5051 to get started and build projects; however, I was wondering if anyone has been able to change build specifications without opening the Application Builder dialog?  -> I would like to build an app. with a version number using the command syntax:  labview.exe <mybuild.vi> -- "project1.lvproj" "version number"
    Any thoughts regarding this problem?
    Thanks,
    Adam

    I have done some research and there doesn't seem to be a way to change the version number when building a project with this method.  If I find out otherwise I will post to let you know but I don't think it is possible.  I would look for another way to accomplish what you want by incorporating the version into the file name or something like that. 
    Eric A.
    National Instruments
    Distributed I/O Product Support Engineer

  • MIGO : CHANGE FIELD STATUS FROM DISPLAY TO EDIT FOR BATCH

    DEAR GURU
    I HAVE CONFIGURED SHELF LIFE FOR OUR PLANTS. WHEN A PLANT USER CREATING RESERVATION FOR SHELF LIFE ITEM , SYSTEM IS ASKING FOR BATCH NUMBER & THEY ARE SELECTING ANY  BATCH FROM F4 LIST.
    AFTER THAT WHEN STORE USER IS CREATING ISSUE SLIP  AGAINST THAT RESERVATION, BATCH NO IS SHOWING IN DISPLAY MODE . COULD WE CHANGE THIS FIELD FROM DISPLAY TO EDIT MODE, SO THAT IF PLANT USER ENTERED WRONG BATCH ,STORE USER CAN CHANGE IT DURING ISSUE SLIP.
    REGARDS
    RAJ

    hi..
    Please check.
    MSC2N or MSC5N....

  • Change system status from PDLV to DLV

    Hi All
    Please help me with this error. Already tick the delivery compeleted in Goods Receipt Tab but then system status won't change from PDLV to DLV. Is there any other way wherein I could change it?
    Thank you
    Jesielle

    Hi Jesielle,
    We're facing the same issue with you. The status remains at PDLV even though we had set the "Delivery Completed" indicator. This only happens to Production Orders that having multiple Items.
    Please share on how you resolved this issue?
    Thanks.
    Regards,
    Hooi Chia

  • Need to change MRP status from Reserved to Fixed - AFS

    Hi,
    I need to change the MRP (allocation) Status (J_3ASTAT) from reserved (R) to Fixed (F).
    transaction  - j4ab
    table - J_3ABDBS (AFS Requirement - Stock assignment) or any other table for this to be updated?
    Do any one have any idea about the Function module or any other procedure to achieve this?
    Thanks,
    Nilanjana

    Hi Nilanjana,
    Yes. You could do this using J4AB.Allocation->Release.
    In the j_3abdbs table, J_3ASTAT field would get changed from "R" to "F".
    The include is /AFS/ARUN_MANAGEMENTTOOL_FCO0Q.
    Best Regards,
    Anitha.

  • Form Change it status from Query to others without any reason

    Hello,
    I have two forms(develper 10g R2) first one works fine if I call that form via menu and want to exit without any modification or insertion it will not ask for saving or cancelation but the second form ask every time for saving and cencellation when I call that form, without any modification/insertion the problematic form have three blocks first block is Control block(database block =NO) and when I called form the cursor moves directly in to the Control block and if I want to exit without touching anything it ask for saving/cancelling,
    on exit I wrote code like this
    IF :SYSTEM.FORM_STATUS <> 'QUERY' THEN
    ELSE
    exit_form(no_validate, full_rollback);
    end if;
    some one have idea why.
    Thanks and Regards, Khawar.

    Hi SIS,
    I ran form in debug mode and continuesly monitor form status, it start with Status of NEW(is it normal??), since the status is new it ask for saving/cancel, I have another form(which behave normal) I did same with it, it also start with NEW status but when I assign a value to an item resides in Control block in WHEN NEW BLOCK INSTANCE trigger the form status changes to QUERY, so I applied same here and assign dummy value to dummy item, and it works fine.
    Thanks, Khawar

  • Change Notification status from NOPR back to OSNO

    Is this possible?... i hope you can help me.

    Hi Anji,
    I've tried EXIT, but i did not find a place where i could specify the status. And the BADI is seems to be used for user status, can I use if for standard status?
    Thanks!
    Peng

  • Change profile value from pl/sql

    nm
    Edited by: Jason ORCL on Jun 2, 2009 9:11 AM

    Hi,
    Just my 0.02 but:
    You might find the right answer on the [HRMS | http://forums.oracle.com/forums/forum.jspa?forumID=113] forum:
    http://forums.oracle.com/forums/search.jspa?objID=f113&q=profile+value

  • Changing OSM task state/status from another parallel task flow

    Hi, guys!
    I have a problem with implementing parallel task flow. Let's consider such situation: there are two parallel task flows, the first flow contain manual task, upon completion which I need to change second flow's task state/status and vice-versa. I studied XMLAPI functions, wsapi operations, api from automation package but couldn't find appropriate aproach.
    Thanks!
    Edited by: serj129 on 15.08.2011 2:50

    Have you any suggestions?
    I tried to implement 2 automation task, which contain automation plugins. First task implemented xquery sender as completed event, the second task implemented xquery reciever, which changes status to success, but this approach isn't working.
    All properties of automation plugins configured properly, but I always receive next exceptions:
    ####<Aug 22, 2011 4:39:52 PM ALMT> <Warning> <EJB> <car07-eth0.telecom> <AdminServer> <ExecuteThread: '13' for queue: 'oms.automation'> <oms-automation> <> <> <1314009592567> <BEA-010065> <MessageDrivenBean threw an Exception in onMessage(). The exception was:
    java.lang.RuntimeException: No transaction associated with request.
    java.lang.RuntimeException: No transaction associated with request
         at oracle.communications.ordermanagement.cluster.message.ClusterMessageHandlerBean.onMessage(Unknown Source)
         at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:466)
         at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:371)
         at weblogic.ejb.container.internal.MDListener.onMessage(MDListener.java:327)
         at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:4585)
         at weblogic.jms.client.JMSSession.execute(JMSSession.java:4271)
         at weblogic.jms.client.JMSSession.executeMessage(JMSSession.java:3747)
         at weblogic.jms.client.JMSSession.access$000(JMSSession.java:114)
         at weblogic.jms.client.JMSSession$UseForRunnable.run(JMSSession.java:5096)
         at weblogic.work.ExecuteRequestAdapter.execute(ExecuteRequestAdapter.java:21)
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)
    >
    ####<Aug 22, 2011 4:39:52 PM ALMT> <Warning> <EJB> <car07-eth0.telecom> <AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1314009592571> <BEA-010216> <The Message-Driven EJB: BiTTLautomation.BiTTLautomation.OSMManualListenerMDB is throwing exception when processing the messages. Delivery failed after 185 attempts. The EJB container will suspend the message delivery for 60 seconds before retry.>
    ####<Aug 22, 2011 4:40:09 PM ALMT> <Info> <oms> <car07-eth0.telecom> <AdminServer> <Timer-8> <admin> <> <> <1314009609038> <BEA-000000> <impl.OrchestrationCascadingLRUPolicy: Evicted order /order/474 from orchestration cache due to cache entry expiry>
    ####<Aug 22, 2011 4:40:24 PM ALMT> <Info> <oms> <car07-eth0.telecom> <AdminServer> <ExecuteThread: '13' for queue: 'oms.automation'> <oms-automation> <BEA1-08945C597092560E5D6A> <> <1314009624879> <BEA-000000> <plugin.AbstractAutomator: Creating automation plugin [class oracle.communications.ordermanagement.automation.plugin.XQuerySender_iults7_Impl] built using SDK version [7.0.2.437]>
    I suggest that it is not correct approach, because of automation context restored from DB is related to other task.
    Have any ideas of changing task status from OSM DB directly. This approach is temporary, for compatibility with performing manual tasks in 2 systems: OSM and other
    Thanks!
    Edited by: serj129 on 22.08.2011 3:59
    Edited by: serj129 on 22.08.2011 3:59

Maybe you are looking for