Solved

what is PLSQL code for cancel 'enter_query' mode

Posted on 2003-11-11
12
1,824 Views
Last Modified: 2007-12-19
For the menu command Query, Enter we have the PL/SQL command Enter_Query.
For the menu command Query, Execute we have the PL/SQL command Execute_Query;
For the menu command Query, Cancel we have the PL/SQL command ????????
0
Comment
Question by:Alta_
12 Comments
 
LVL 15

Expert Comment

by:andrewst
ID: 9721520
It is:

IF :SYSTEM.MODE = 'ENTER-QUERY' THEN
  EXIT_FORM;
END IF;
0
 

Author Comment

by:Alta_
ID: 9721570
I tried this and didnt work.
I could exit the enter_query mode only by pressing CTRL+Q..or the 'Cancel query' button...
But I'm interested to do it with PL SQL code.
Maybe there is a way to simulate pressing the
'CTRL+Q' keys?
0
 
LVL 13

Expert Comment

by:anand_2000v
ID: 9721640
I think a clear_form(no_validate) will help.
0
 
LVL 15

Expert Comment

by:andrewst
ID: 9721653
How come it didn't work?  It does when I do it.
0
 
LVL 22

Expert Comment

by:Helena Marková
ID: 9721700
andrewst answer MUST work ...
0
 

Author Comment

by:Alta_
ID: 9721718
Simply it didn't work.
I have a form with a master-detail block...and I want to make some control buttons.

I made a "search" button and want to fill one item with some value (in order to do 'execute-query' after this...to filter some records). I wrote the trigger 'when-button-pressed'  for this button with this code:
enter_query;

I want to make a "cancel" button to exit this
'enter_query' mode...but I cant.
Only button from standard menu work (Cancel Query) or CTRL+Q from kbd.



0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 15

Accepted Solution

by:
andrewst earned 50 total points
ID: 9721796
That's what I did just now before I gave my answer:

1) Created a new form
2) Created a simple base table block based on table DEPT
3) Created a button (in block DEPT as it happens) with the following code:

IF :SYSTEM.MODE = 'ENTER-QUERY' THEN
  EXIT_FORM;
ELSE
  MESSAGE('Not currently in enter-query mode' );
END IF;

I then ran the form and did these tests:
1) Pressed my cancel button immediately: got message 'Not currently in enter-query mode'
2) Pressed Enter Query toolbar button
3) Pressed my cancel button again: got message 'FRM-40353:  Query cancelled'

I can only imagine you have made a mistake in your attempt to implement this somehow.

0
 

Author Comment

by:Alta_
ID: 9721861
I did aprox. the same with the single table...and I succeded.

But when I use a master-detail block..so a parent table and a child table...things dont work...never  got message 'FRM-40353:  Query cancelled' ....only 'press F8 for execute and CTRL_q for cancel.'

So I think the problem is from this relation?
Could you try for a master-detail block?


0
 

Author Comment

by:Alta_
ID: 9721874
I forgot to say I have 3 blocks:
-one for master(parent)
-one for detail (child)
-one for control buttons
0
 

Author Comment

by:Alta_
ID: 9721909
wow...
If I move the control buttons to master block data (parent)...it works ...as you said.

What to do then...to make work.. if this buttons are in the different block (not data block) ?
0
 
LVL 15

Expert Comment

by:andrewst
ID: 9721943
In the button properties, set Mouse Navigate = No, then it should be OK
0
 

Author Comment

by:Alta_
ID: 9722019
Yes :)
its works now!!
thanks a lot!
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Oracle SQL Query Syntax 6 85
Space Delimited Sql File 4 70
dates - loop 12 41
Oracle Next Available Number 2 17
Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
Via a live example, show how to take different types of Oracle backups using RMAN.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now