UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Search Engine    
 
   
kelvindavies11
post Apr 2 2007, 03:07 AM
Post #1

New Member
Posts: 10



Hi all,
Hi, I'm currently working as a graduate within a computer company and have been asked to create a database that will hold information concerning a traceability matrix. I have created the outlines of a relational db, but have a little problem.

Within a recent meeting i have been asked to provide the facilty for the user of the db to be able to search for records, according to different conditions. So my idea is to provide the user with a text field box(search criteria) and then display the result in a subform. I assume the information that will populate the subform will come from a query, based on the criteria provided.

Is there a tutorial or example of how do do this?Do you kow a better way of be doing this. If you would like more information concerning teh db please ask.

Thanks.

kelvin
Go to the top of the page
 
+
prebez
post Apr 2 2007, 03:18 AM
Post #2

UtterAccess Guru
Posts: 908
From: Copenhagen, Denmark



I would filter the main form according to the criteria entered. That would be a lot easier.

Hht

Jock
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 03:20 AM
Post #3

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi Kelvin
Welcome to Utter Access Forums

QUOTE
according to different conditions.


Base on the above statement this article would be a good starting point..
How to use the Query by Form (QBF) technique in Access .
QUOTE
SUMMARY
This article shows you how to use a form to specify the criteria for a query. This technique is called query by form (QBF).
Back to the top

MORE INFORMATION
In the QBF technique, you create a form in which you enter query criteria. This form contains blank text boxes. Each text box represents a field in a table that you want to query. You make entries only in the text boxes for which you want to specify search criteria.

The QBF form resembles a data entry form that has fields that match the fields in a table. A table that has fields for Name, Address, City, State, and Zip Code can have a QBF form that has corresponding fields. To select certain records, you can enter any combination of search criteria in the form. You can specify a city only, or a city and a state, or a zip code only, or any other combination. Fields that you leave blank are ignored. When you click a command button on the form, Access runs a query that uses the search criteria from your form.

HTH's
(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 04:36 AM
Post #4

New Member
Posts: 10



Larry, thank you for your welcome and thanks for the link.

I understand and have implemented that link inot the db, however how do i get the information produced by qbf to populate a subform instead of appearing in a popup window?

Thanks again.
kelvin
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 04:41 AM
Post #5

New Member
Posts: 10



sorry thanks for your input also prebez.

kelvin
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 04:50 AM
Post #6

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi Kelvin
Your subform should be based on a query and you apply those filtering instructions from the link to filter out your data, here is another link to a working example and code on how to implement a search form/subform.
Sample Search Form Version: 2002 (10.0) XP by Lou kappeller..
Check it out.
(it's good)
(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 07:39 AM
Post #7

New Member
Posts: 10



Larry, thanks for that it helped loads.

One last question, I think (IMG:http://www.utteraccess.com/forum/style_emoticons/default/sad.gif)

How do i do a search that will show the links between the realational db. IE how can i show all the usecases for a particular requirement.

thanks again.

kelvin
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 07:45 AM
Post #8

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi kelvin
Not sure I understand..? "links between the realational db"..

(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 07:49 AM
Post #9

New Member
Posts: 10



Sorry poor explaining.

BG info:

I have a table holding Requirement info, and a table holding usecase info.(M-2-m relationship)So i create a assign usecase table.

What i want to do is, search for a requirement and then display the requirement and the associated usecases.

Did i explan that better?

kelvin
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 08:25 AM
Post #10

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi
Would you have a junction table between Requirement and usecase.. tables.
eg:
tblRequirement >> jtblRegUseCase << tblUsecase
(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 08:33 AM
Post #11

New Member
Posts: 10



Thats what i have got. But how do you collect this information and display it in teh following way:

Requirement 1
Usecase 1
Usecase 2
...

Thanks again,
kelvin
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 08:38 AM
Post #12

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



HI
Using a select query that has all three tables as it source..
The junction table should hold all instances of a requirement and usecase that are brought together as a single record under a unique id in the junction table.
HTH's
(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 2 2007, 09:01 AM
Post #13

New Member
Posts: 10



Another question i have is how do i write a query to search for requirements that have no connections to a usecase??

Thanks allot for your time,
kelvin
Go to the top of the page
 
+
Larry Larsen
post Apr 2 2007, 09:04 AM
Post #14

UA Editor + Utterly Certified
Posts: 22,722
From: Melton Mowbray,Leicestershire (U.K)



Hi
Have you checked out the "Find Unmatched Query Wizard"..
(IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif)
Go to the top of the page
 
+
kelvindavies11
post Apr 3 2007, 07:27 AM
Post #15

New Member
Posts: 10



How is everyone today??

I have used a query to produce details for a report, however i have one problem. The report produces a list list of requirements and their associated useacses.

My problem is that if i create a report using the query, and then add another usecase , then it will not show up on teh report. IS there a way of updating a report before it is previewed.

Also i would like to create a report that details how many requirements i have, how many usecases i have etc, how do i do this?

Thanks again for your help.

kelvin
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 24th May 2013 - 06:28 PM