How to exit from the loop
loop at itab.
if <CONDITION>
<EXIT LOOP>
endif
endloop.
this ths condition , pz tel how to exit from loop
Hi
Loop
statements
EXIT
Endloop.
Will comes out of the loop.
Regards,
Sreeram Kumar.Madisetty
Similar Messages
-
How to exit from a loop on 2 different conditions
Hello Experts
I’m trying to write a procedure in which I’m taking PROVINCE as an input parameter. All the provinces are stores in a table. I’m using a cursor and rowtype variable to check the province. After I finds province I displays province and its code. Everything works fine expect when I don’t find the province. I’m not sure how to exit from loop if I don’t find the province. I already uses exit when condition. I was expecting else condition should work and should exit from the loop but it doesn’t. Can please somebody show me how to exit if I don’t find province in the table through cursor.
Here is my code
set serveroutput on
variable G_TAX varchar2(10)
CREATE OR REPLACE PROCEDURE p_create(i_state VARCHAR2)is
CURSOR cur_bb_tax is
select * from bb_tax;
bb_tax_details bb_tax%rowtype;
begin
if not cur_bb_tax%isopen then
open cur_bb_tax;
end if;
loop
fetch cur_bb_tax into bb_tax_details;
if (bb_tax_details.state = i_state) then
dbms_output.put_line(bb_tax_details.state || bb_tax_details.idstate);
end if;
exit when bb_tax_details.state = i_state;
end loop;
close cur_bb_tax;
exception
when others then
dbms_output.put_line(SQLERRM);
end;
Thanks in advanceHello,
Why don't you use dbms_output.Put_line and print output to find why logic is not able to execute? Maybe upper case/lower case/whitespace. *Also put your code between \ to preserve formatting*.
Regards -
How to exit from the button test in diagnostic mode
Hi,
I am having some trouble with my ipod 7th gen.
First my lightning cable wont be recognize. show the error Accesory incompatible.
I try to solve the problem cleaning the golden pins in the cable and in the ipod. Don't work
I enter in diagnostic mode in my ipod and I get stucked in the button counter test..
In the screen appear a mesage 'Please reset the unit to end'. I don't know how to reset the unit
I press any button and only increase the counter for every button.
First how acan exit from the button counter test and how can fix the issue with the lightning cableYour problem is that you are trapped inside an event case. It is not a good idea to run extended code inside event cases, else the event structure cannot service other events.
Why don't you use the outer loop for everything? Now things don't step on each others toes. What good is an event structure if it cannot react at all times???
Message Edited by altenbach on 07-25-2008 12:26 AM
LabVIEW Champion . Do more with less code and in less time .
Attachments:
event_problemMOD.vi 17 KB -
How to exit from the class execution process?
I am invoking an exe from my Java application using the Runtime.getRuntime().exec() method.
though the process is completed, the class is still running.
how do i exit from the class execution, but with the process still running??To sabre150 :
I am directly executing the command through the exec() method:
Runtime.getRuntime().exec("...../iexplore.exe");This way, the control is going to the opened IE window and only on closing it, my class is exiting.
Is there any other way where I can come out of the class, but ensure that the process which i run through the exec() method, is still running? -
How to exit from the DO-while loop in the event structure
Hi all
I am just a beginner for Labview
I want to build a loop in the event structure, but when I enter in the loop, it seems the system is dead, and I can't exit the loop.
here I attached a simple sample.
In the sample. when I press the start_calculation button , the calculation start, but the system is dead, and I can't exit calculation loop.
actually, i just want switch the different operation by changing the event action.
anybody has a good idea about it??
thanks so lot
Attachments:
event_problem.vi 17 KBYour problem is that you are trapped inside an event case. It is not a good idea to run extended code inside event cases, else the event structure cannot service other events.
Why don't you use the outer loop for everything? Now things don't step on each others toes. What good is an event structure if it cannot react at all times???
Message Edited by altenbach on 07-25-2008 12:26 AM
LabVIEW Champion . Do more with less code and in less time .
Attachments:
event_problemMOD.vi 17 KB -
Hi
I want to exit from loop if error is encountered.
THanksHi Sonu,
This is not a question related to the SDK. This is more of a coding question you should probably try something like StackOverflow or MSDN forums for that next time.
Regarding your question it depends on the language you are using. If you are using c# you can use the keyword "break;" inside an if that checks for the error. In VB you can use "Exit For" or "Exit While".
Best regards,
Pedro Magueija -
How to exit from loop after 3 time
hi
how to exit from loop after 3 time
loop at itab.
<exit after 3 time>
endloop.
thanksHi,
You can check the value of SY_TABIX inside loop,
For Example:
Loop at itab.
if sy-tabix = 3.
Exit.
endif.
Endloop.
Hope it helps
Regrds
Mansi -
How to track exit from the PageFragment Lifecycle
Hi,
I have a requirement of keeping track of exit from a pageFragment.
My structure contains: a TaskFlow which contains a train . This train node contains the page Fragments. Now when i navigate from one PageFrag to another ie. when i exit the currently selected node having a page Fragment, i need to fire a logic.
I tried using creating a bean which implements RegionController interface which has refreshRegion(RegionContext ) method.I got hold of RegionBinding interface which has only one of the following values: Entry, Execute_Model, Prepare_Model, Refresh_Unknown, Render_Model and Type_executable_region.
Also in this case i am not exiting the TaskFlow during the navigation.
My doubt is how do i or can i use RegionController to keep track of exit from the currently rendered PageFragment's Lifecycle.
Also , can i use PagePhaseListener to keep track of the PageFragment lifecycle stage. (My understanding is PagePhaseListener is to be used for Jspx not Jsff). Plz do correct me if i am wrong.
Thanks,
Prasenjit
Edited by: user586616 on Aug 31, 2009 3:54 AM
Edited by: user586616 on Aug 31, 2009 3:57 AMHi Frank,
I have created a ControllerClass which implements RegionController. I have registered the same as controller class in my pageFragments PageDef.
So, on navigation from one train node to another. due to post back call to leaving node and freshcall to the arriving node in the train flow. i am able to get the leaving as well approaching node.
My doubt is can i get similar or better control over the nodes traversed using trainModel or anyother adfinternal controller class? Kindly suggest any better way of getting handle to the navigating train nodes.
Sample Code which i have implemented:
public class RegionControllerBean implements RegionController {
public boolean refreshRegion(RegionContext regionContext) {
System.out.println("**********************************");
System.out.println("inside refreshRegion method call");
String selectedView = ControllerContext.getInstance().getCurrentViewPort().getViewId(); ------> this gives me the handle to the viewId of the curently selected pageFragment
System.out.println(ControllerContext.getInstance().getCurrentViewPort().getViewId().toString());
String pageName = selectedView.split("/")[2];
System.out.println("Current PageName:"+pageName);
System.out.println("name: "+regionContext.getRegionBinding().getName());
int refreshFlag = regionContext.getRefreshFlag();
if(refreshFlag == RegionBinding.PREPARE_MODEL){
System.out.println("Inside prepare Model phase"); ------> on entering of that node i need to call some logic before prepare_model phase
if(refreshFlag == RegionBinding.EXECUTE_MODEL){
System.out.println("Inside execute model phase");
if(refreshFlag == RegionBinding.RENDER_MODEL){
System.out.println("Inside render model phase");
// propagate refresh to inner binding container
regionContext.getRegionBinding().refresh(refreshFlag);
return false;
public boolean validateRegion(RegionContext regionContext) {
// propagate the validate to inner binding container
System.out.println("inside validate region method");
regionContext.getRegionBinding().validate();
return false;
thanks,
Prasenjit -
How to exit from whileloop with Timing Delay
Hello;
How to exit from forwhile with timing wait (10s) before finish 10s by stop botem;
exemple ; first impulsion to start a while loop with 10 s wait ,before finsh a 10s second impulsion to stop the while loop; in labview 2010
best regrds
Forza JuventusShow us the code you currently have. Just repeating your specification word-for-word is not going to help us to understand you problem.
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines -
How to exit from a WebDynpro ABAP application and open another url
Hi Friends,
How to exit from a WebDynpro ABAP application and open another url like (www.yahoo.com) in the same window of the WD4 application on click of a Button?
Regards,
XavierHi,
First of all you should create outbound plug in the window you are trying to exit with plufg type "Exit"
Then create method handler in the view with this code
data lo_view_cntr type ref to if_wd_view_controller.
data lo_win_cntr type ref to if_wd_window_controller.
data: l_parameter_list type wdr_event_parameter_list,
l_parameter type wdr_event_parameter,
l_val type ref to data,
l_val_url type REF TO data.
field-symbols: <fs> type any,
<fs_url> type any.
lo_view_cntr = wd_this->wd_get_api( ).
lo_win_cntr = lo_view_cntr->get_embedding_window_ctlr( ).
CREATE DATA l_val type c.
CREATE DATA l_val_url type string.
ASSIGN l_val->* to <fs>.
ASSIGN l_val_url->* to <fs_url>.
<fs> = 'X'.
<fs_url> = 'http://your-link.com'.
l_parameter-name = 'URL'.
l_parameter-value = l_val_url.
INSERT l_parameter INTO TABLE l_parameter_list.
lo_win_cntr->if_wd_view_controller~fire_plug( EXPORTING plug_name = 'EXIT_PLUG'
parameters = l_parameter_list ).
You can easily change this logic to exit application instead of redirecting to the site
just changing to
l_parameter-name = 'CLOSE_WINDOW'. -
Portal logoff should Close or Exit from the window
Hi Friends,
Please help me here, When user click on logoff or Exit from the portal the Window should be closed. (I disabled the popup message box , now I am trying to figured it out how to close the window)
Please help me.
PeterHi Peter,
If you try to write JavaScript in par file to close window, i think portal will not properly logoff from portal.
Better to create a seperate html page which contain script to close the window on load. Also include script to remove cookies created by portal (not mandatory). Save the html page in server..
You can redirect portal after logoff to this page by setting ume logoff url in visual administrator.
We implemented this in portal and working fine in IE. For Firefox it will prompt a message, since it will not allow close window from script due to security reasons.
If you need html code and script let me know i will send it.
Regards
Baby -
Conditional Exit from the script
Hi,
I have to code the script like the below
--Step 1
begin
If <Table1 doesnot exist> then
Display "User Defined Error Message: Table1 doesnot exit"
EXIT FROM THE SCRIPT(Below sql should not run)
endif
end
--Step 2
spool abc.txt;
select "should not run" from Table1;
spool off;Step 2 should not run if table1 doesnot exist.
Can someone please tell how to conditionally exit the script.
Thanks & Regards,C
CDPrasad
Edited by: cdprasad on Aug 12, 2010 1:35 PM
Edited by: cdprasad on Aug 12, 2010 1:36 PM
Edited by: cdprasad on Aug 12, 2010 1:38 PM
Edited by: cdprasad on Aug 12, 2010 1:38 PMHi,
David is right; SQL*Plus is the wrong tool for this job.
If you really want to to this in SQL*Plus, you can achieve a crude type of branching by using sub-sripts. Instead of an IF statement, you use START or @ to run one or another of those sub-scripts, based on a substitution variable, which in turn is set by a query.
For example:
-- abc.sql - Test if table1 exists, and
-- (1) if it exists, run abc_query.sql to do a query
-- (2) if it does not exist, run abc_error.sql to display an error message
-- Preliminary query, to define next_script:
COLUMN next_script_col NEW_VALUE next_script
SELECT CASE COUNT (*)
WHEN 0 THEN 'abc_error'
ELSE 'abc_query'
END AS next_script_col
FROM all_tables
WHERE table_name = 'TABLE1'
AND owner = 'SCOTT'
-- Now that we know what to do, do it:
@&next_scriptYou would run the above script (abc.sql) and it would decide whether to run the script containing you query, or the script that prints an error message.
Why does table1 sometimes disappear? In a good database design, tables are permanent structures, and get dropped only when they are obsolete. Perhaps you should be TRUNCATing the table, not dropping it. -
How to Exit from Session by executing program
How to Exit from Session by executing program
Hi,
Try the following
CALL the function module HLP_MODE_CREATE and pass '/nex' to tcode import parameter.
Regards,
Sesh
Message was edited by: Seshatalpasai Madala -
How to exit from recovery mode?
how to exit from recovery mode?
You could try a hard reset
- hold the home button and the sleep/wake button down at the same time
- the phone will turn off, when the apple logo appears release both buttons
More than likely after this you will still be in recovery mode. If so then you would need to restore the phone through itunes on a pc/mac.
Hope this helps -
Deleting from the loop browser
Is there a way to delete loop names from the loop browser drop down list and the actual loops themselves? I inadvertently (sp?) added loop folders that I had bought and downloaded to the loop browser without first naming the loop folders being added. So I now have a few generically named "apple loops" in the loop browser drop down list. I have since renamed the original folders and added it to the loop browser. I now have 2 copies of loop names in the drop down list; the only difference being the generic "apple loops" as opposed to the specific name of the loop folder added. I'm assuming I also now have two copies of the loops themselves since the names in the drop down list are different, which, of course, means more HD space being taken up. I cannot find anything about deleting this. I can't believe there isn't a way to do this. Any help?
Stevereindex your loops:
http://www.bulletsandbones.com/GB/GBFAQ.html#reindex
(Let the page FULLY load. The link to your answer is at the top of your screen)
Maybe you are looking for
-
Webdynpro ABAP/Portal. Plugin HTTP connection issue on WaitingEventQueue.js
Hello, We are experiencing a strange Portal Behavior with our Webdynpros. Our portal contains several iViews including some Webdynpro (ABAP) and some reporting transaction calls that use SAPgui for HTML. When portal is called for the first time and a
-
Some pictures not synching on photo stream
I'm having a problem witht the photo stream. For some reason, of the 25 or so photos I have taken on my iphone, a few do not get synched to the Photo Stream. I've tried resetting PS (ie turning it off and then back on again) but the same few pictures
-
Coldfusion query of queries error
I have a long query named "Results.Itinerary" in a CFC which I have to add this query to. <CFLOOP QUERY = "Results.Itinerary"> <CFQUERY NAME = "GetPorts" DATASOURCE="x"> SELECT * FROM Itinerary_Ports WHERE (ItineraryID = #ItineraryID#) AND (Name NOT
-
Tax code S7 may only contain one assignment line (Message no. FF731)
Dear All, I am getting above error while processing Batch session genrated by S_AC0_52000644. I have searched SDN and found the similar kind of error but that message was related to Tax Procedure TAXINN where as we are useing tax procudure TAXINJ. An
-
Hello all, I have some questions about clustering in Ironport: Actually I have one IronPort C150 in "Standalone mode" with an ip adress who takes the mail flow (192.168.1.34) We received a second Ironport for setup a cluster configuration between the