Solved

Filtering of information of database using other database

Posted on 2011-02-18
8
845 Views
Last Modified: 2012-05-11
hello experts,

I have 2 database (Maindb and weldersdb), and a form (MAINFRM), eventually mainfrm is linked to maindb, now some information i need to show from weldersdb in mainfrm based on the data i typed
example
Weldersdb information

Welders     Process
ERS-001         S
ERS-002         F
ERS-003         S

now, if i type 'S' in the fileds 'process' in mainfrm the welders will show only 'ERS-001' and 'ERS-003', and if i type 'F', 'ERS-002' is the only welders that will show.

Can anybody help me with this.

Thank you

CZHER  
 
0
Comment
Question by:Czher
8 Comments
 
LVL 18

Expert Comment

by:Jerry Miller
ID: 34931527
If you have linked tables, then you can create parameter queries on any field in the table and filter it as you please.

http://www.ehow.com/how_2020612_create-parameter-access.html
0
 
LVL 119

Expert Comment

by:Rey Obrero
ID: 34931529
you create a link from Maindb to the table in weldersdb

file > external data > linked tables


once you have created the link, you can then use the linked  table like a local table
* as a record source of a form
* as row source of a combo/list  box

i don't exactly understand what you meant by this

<now, if i type 'S' in the fileds 'process' in mainfrm the welders will show only 'ERS-001' and 'ERS-003', and if i type 'F', 'ERS-002' is the only welders that will show.>
0
 

Author Comment

by:Czher
ID: 34931557
capricorn1,

in mainfrm there is a fields (welders, date, process),

This is the informaiton you're gonna see in weldersdb

Welders     Process
ERS-001         S
ERS-002         F
ERS-003         S

This is the information you're gonna see on MAINFRM

Welders       Date       Process
ERS-001   01/01/11        S


as ive mentioned above

if i type in mainfrm 'process' = 'S' the welders in combo box that will show is 'ERS-001' and 'ERS-003', but if i typed in mainfrm 'process' = 'F' the welders in combo box that will show is 'ERS-002'

in other words welders that will show only in combo box in mainfrm is depending on the process i will typed.

I hope this is clear

0
 
LVL 39

Expert Comment

by:als315
ID: 34931912
Can you upload you DB with sample of data?
0
Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

 

Author Comment

by:Czher
ID: 34932281
I uploaded the DB, if you check the Welderdb each welder has a corresponding process, what i want to do in mainfrm is when i type or select in process field 'S' or 'F' or anything, not all welders will show but only those welders with the same process  that i type will only appears.

I hope this file will help you understand what i need.

Thanks
WeldSys.mdb
0
 
LVL 119

Accepted Solution

by:
Rey Obrero earned 500 total points
ID: 34933175
use this codes in the afterupdate event of combo Process


Private Sub Process_AfterUpdate()
Dim sql
sql = "SELECT ID,Welder, Process"
sql = sql & " FROM WELDERDB Where Process ='" & Me.Process.Column(1) & "'"

Me.Welder.RowSource = sql
End Sub



WeldSys.mdb
0
 
LVL 31

Expert Comment

by:Helen_Feddema
ID: 34933342
See my Fancy Filters database for an example of filtering a subform by a number of different values (different data types).  Here is a link for downloading it:

http://www.helenfeddema.com/Files/accarch129.zip

and here is a screen shot of the main form:
Fancy-Filters-Form.jpg
0
 

Author Comment

by:Czher
ID: 34935802
Capricorn1,

Thank you verymuch for the help, but why everytime i add a line and select a process, those previous line i already  selected, the welder is disappearing?
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
The first two articles in this short series — Using a Criteria Form to Filter Records (http://www.experts-exchange.com/A_6069.html) and Building a Custom Filter (http://www.experts-exchange.com/A_6070.html) — discuss in some detail how a form can be…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

708 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

10 Experts available now in Live!

Get 1:1 Help Now