Home » Developer & Programmer » Forms » How to perform search detail block. (Oracle Forms 10g)
How to perform search detail block. [message #537038] Mon, 26 December 2011 05:40 Go to next message
irsathahamed
Messages: 12
Registered: April 2008
Location: UAE
Junior Member
Hi everyone,

I have detail block in my form and i need to give option to user to search item in that block.

For example I display 100 items from item master and user need to search particular item by either code or name.

Please help me how will I do this?

Thanks for your help.

Re: How to perform search detail block. [message #537059 is a reply to message #537038] Mon, 26 December 2011 06:55 Go to previous messageGo to next message
azamkhan
Messages: 557
Registered: August 2005
Senior Member
Create a mechanism that take values of item code or item name from user. Then naviagte each record to match the given values with the respected item. If found then message user that search found else search not found.

Tip: Use Loop...End Loop for this. Hope your problem will be solve

[Updated on: Mon, 26 December 2011 06:55]

Report message to a moderator

Re: How to perform search detail block. [message #537100 is a reply to message #537059] Mon, 26 December 2011 13:11 Go to previous messageGo to next message
Littlefoot
Messages: 21813
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I'd use built-in Forms querying capabilities.

Once you navigate into a detail block (which contains many items):
- enter query mode
- enter search criteria (CODE, NAME, whatever)
- execute query

That's all, no additional coding is necessary. If you know how to efficiently query data, wow, you can do magic. For example, you can use wildcards. Or, you can use "Query Where" dialog box (in order to do that, enter - for example - ":a" (without double quotes, just colon a) and execute query - a dialog box will open. It allows you to specify conditions that are too complex to be specified by entering values into items (such as IN clause, subqueries, virtually anything). The best part of it is that you can use the same trick for ALL items (for example, if there are ID, NAME, DATE, you can enter :a, :b, :c for all those items and write your own criteria for each item. Really cool stuff.

So, I'd suggest you to learn how to use what Oracle provides by default. If you can't get the result, then go and write your own solution.
Re: How to perform search detail block. [message #537120 is a reply to message #537100] Mon, 26 December 2011 22:46 Go to previous messageGo to next message
azamkhan
Messages: 557
Registered: August 2005
Senior Member
There will be other things to handle also little foot. Like what to do when there is a change in record etc.

When you are designing an application for client there will be business rules also that you have to keep in mind to make the application usefull.
Re: How to perform search detail block. [message #537121 is a reply to message #537120] Mon, 26 December 2011 22:47 Go to previous messageGo to next message
azamkhan
Messages: 557
Registered: August 2005
Senior Member
And what happend if the user whats all its data on the screen and then wants to perform search.

See this is why we programmer comes in. Smile
Re: How to perform search detail block. [message #537122 is a reply to message #537121] Mon, 26 December 2011 22:59 Go to previous messageGo to next message
azamkhan
Messages: 557
Registered: August 2005
Senior Member
Programming is an ART to me. I love doing programming playing with logic.

I love to make my application / software / code to show the user that " I AM A USER FRIENDLY SOFTWARE". And a user friendly software must feels like that it is very easily to handle even by a Novice user.

And these days because of tight competition in the market a software developer not only have to design a software for a client to perform automation but it must be attractive and colourful (use of graphics, animations etc) and flexable.

And for all this staff you need lots of code with sensible and attractive screen
Re: How to perform search detail block. [message #537124 is a reply to message #537122] Mon, 26 December 2011 23:02 Go to previous message
azamkhan
Messages: 557
Registered: August 2005
Senior Member
What litle foot said for search is also right. But as a professional believe me you will ever want to design using forms default search for your application.
Previous Topic: que: developer 6i patch 17
Next Topic: how to convert data from forms 6i to pdf format?
Goto Forum:
  


Current Time: Thu Jul 25 21:35:10 CDT 2024