Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Enter query

Status
Not open for further replies.

tyb

Technical User
Feb 10, 2004
137
IR
Dear Frends

i'm trying to have a search field in my data block to give the user simple search on the block as its on the web or somewhere that we simply move to the item enter the data to be searched for and click the search button to get the results.

wut i've done is that on the pre-text of the text-item used for search i've written the " Enter_query; "
and to enable the search button which is disabled b4 user enters the search field.

and on the Post_text i'm again disabling the search button.

but when i run the form i cant navigate to the search field.

can some one predict what might be the possible cause.
 
No Dima, the search field is a Non-DB and is in the same block on which i want the query to be executed.
The search item is just to get the value into the original filed in the Pre-Query trigger (Original item is Display item).

many thanks for this response

 
oh that might be the possible error.

then can u suggest where to do it to get the same functionality.

Thanks Dima and Lewisp.

Regards
 
Why bother with enter query mode at all? Just allow the user to type a value into the control field (that is in another block), then modify the WHERE clause on the main block to take the control field into account. Then a button next to your control field would have one line in it: exectue_query;
 
Thanks lewisp
sorry for being absent for such a long time so couldnt check ur reply

it seems to be the exact solution but i dont know how to reset the blocks where clause after the query is executed and at that point if i dont reset the where clause the form will try to search for some record with null value .
is it ? if so what would u seggest.

thanks in advance


 
You could store the current value of the DEFAULT_WHERE on the block, and then reinstate it once your query has completed.

If you're using forms 9i you can use ONETIME_WHERE.
 
thanks dima, but if i use non-updateable text field it will become non-updateable for the values that's been saved to the DB but not for those written in the text field and will give the user option to enter the value which i dont want as i'm inputing the values from a sequence.

please suggest
thanks again.
 
sorry dear may be i'm wrong but it's true in forms-5 as i myself experience that. pls check if u'v any doubt.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top