Finding Info In Another Table

May 11, 2005

Please note that I am self taught (90% of what I have learnt has been off these boards!). I did make this form with info I found on this forum.
I am having problems with a log in box for a database, the line of code is -
If Me.txtpassword.Value = DLookup("password", "customers", "[customerID] =" & Me.EbayName.Value) Then
This code is in a Form; "password" is the value in the table of "customers"; [customerID] is the primary key value I wish to remember; Me.EbayName.Value I assume is the value in the table that access is looking for.

Questions -
A) It is not looking up the value for [customerID] - what have I done wrong?

B) In the line of Me.EbayName.Value what does the 'Me.' part tell Access to do? I assume it's a pointer to it's own form? What part of the line do I need to change to make it point to another form (or table)?

C) When this is finished how do I get the program to remember the 'customerID' while the customer is fillling out other forms?

James

View Replies


ADVERTISEMENT

Search Forms - Finding A Contact And Displaying All Related Info

Nov 22, 2005

Hi

I am pulling my hair out with what I am sure is a simple task, creating a search form that, when criteria are entered, finds a record and displays related data/results from 3 tables. I have tried every forum and web post I can find but I think there must be something fundamental I'm neglecting to grasp.

Quick background:
My database has 4 tables, Firm, Contacts, Mailout and FileNote
The database is contact-centric (ie, everything is linked to a contact record, multiple contacts are held against firms, mutiple file notes are held against a contact, contacts can be attached to multiple mailouts)
I need to search for a contact record based on multiple criteria (keeping it simple, lets say a combination of first_name & last_name OR first-name & firm_name OR their specific contact ID)
I need a 'results form' (not just a datasheet view) that displays all information related to that contact (i.e. all files notes + ability to create new ones, firm contact information, and mailout history)


I've created a Main form with Firm, Mailout, Contact & Filenote subforms embedded that enables me to scroll through every contact and view all related detail (as above) and add file notes & modify data very nicely. My problem is I can't search, I can only move through each record sequentially. Very handy when we have 4000 contacts!

I realise I'm probably a complete wally but could someone please explain to me the vital steps I'm missing? I've tried unbound fields, I've built SQL queries & command buttons (but results are dumped into a datasheet)....I'm lost.

Many many thanks.

View 2 Replies View Related

Queries :: Finding Distinct Records In Table A That Are In Table B

Dec 19, 2013

tbl_A has column "ID" with duplicates. tbl_B has column "ID" with distinct values.i want to find all the distinct IDs in tbl_A that are present in tbl_B.I've tried the following with no luck:

SELECT DISTINCT tbl_A.ID
FROM tbl_A LEFT JOIN tbl_B ON tbl_A.ID = tbl_B.ID
WHERE tbl_A.ID IN tbl_B.ID;

View 3 Replies View Related

Queries :: DSum - Update A Field In Specific Table With Info Form Another Table

Aug 5, 2014

I have a table products with a field "id_product" and "total" (Total items in stock)

I have a query with the fields "id_product" and also the field "total in stock"

I want an update query to update the field 'total' in table 'products' with infos from that query

For each id-product in table products, replace the field total with the field 'total in stock' from the query

So I want to update a filed in a specific table with infos form another table.

View 2 Replies View Related

Populating Master Table With Info From List Table

Aug 29, 2006

I have a form that I am working on.

When you open the form, it asks for a tool # (which will be a drop-down box). There will be a command button that will bring up a sub-form. In the subform, there are 2 combo boxes. One picks the group that the tool falls under, and the other has the section of the group for the tool.

When the user picks the section, I need it to filter the questions that pertain to that section (which is listed in a list table), and pull those questions, and populate the master table with them. (i.e., Pulls "where is tool?" from tblQuestions, and puts it in the tblQuestionMaster when section is selected from combobox).
:confused:

View 1 Replies View Related

Finding Records Within One Table - Msg Box

Feb 17, 2005

I have patients and their details all listed in onetable.
I want a message box to come up if a patient also has a family memeber somewhere else in this table. To do this i need to
match surname and mother's christian name.
Ani ideas?

View 1 Replies View Related

Finding Table In Form?

Sep 22, 2011

is there an easy way to find out in wich form a specific table is used.

I have an access application and i need to find out if every table definded is used in the application and in wich form.

I can open each form, see wich tables are used and make a list. But i have a lot of forms and there is the possibility to miss one.

View 2 Replies View Related

Finding Predecessors Within A Table

Mar 11, 2015

I have a table of contracts. These contracts are renewed every year, and therefore many contracts have a version from the previous year, but some are new and have no predecessor. I want to write a query which lists all contracts on the table, together with a reference to any preceding contract with the same customer, or a null if there is none. For example, if the table fields are contract number, customer and year, and the table looks like this:

Contract Customer Year
271 Smith 2013
816 Brown 2013
101 Jones 2013
227 Smith 2012
564 Brown 2012

I want a query which returns:

Contract Customer Year Previously
271 Smith 2013 227
816 Brown 2013 564
101 Jones 2013 null
227 Smith 2012 null
564 Brown 2012 null

View 1 Replies View Related

Need 2 Fields From Table 1 / Using Lookup Info From Table 2 And Put Into Table 3

Jun 28, 2013

I need to get x and y coordinates for each device, but the data has to get looked up from 2 other tables.

I have a table (called InstReclosers) that has device names. Each device is on a Section. I can go to another table (called InstSections) and look up what Node that particular section is tied to. Then I need to go to another table (called Nodes) to get the X and Y location for that particular node.

How I can go about getting this X and Y data into the InstReclosers table?

...in summary, InstReclosers has device name and section name. InstSections has section name and node name. Nodes has node name and XY coords. Need XY coords for each device in InstReclosers.

View 3 Replies View Related

Update Order Info Based On Quote Info

Nov 7, 2006

I need help on this, from what the best concept is, to what I need to look into using:

I store Quote data from phone calls into tblQuotes. There is a seperate table that holds much of the same information except that it is for actual orders called tblOrders.

As far as function goes, I have each working much the way I need it to except for one thing... If a sales person is on the phone with a customer with a quote already in the system, right now they re-enter the data into the Order table. Most times, the order is what was quoted, but maybe with a few small changes (so I will wnt to keep a historical record of the quote). How could I copy the contents of the quote recordset into the recordset for an order, where all the sales rep does from there is edit the quote to the actual order?

Would I use VBA or an update query that is executed via VAB? Honestly, I am unsure how to do this at all, I hope someone has seen this before and has a good suggestion...

Thank you.

View 2 Replies View Related

Tables :: Finding Closest Value In A Table?

Oct 13, 2012

I am working on a DB for maintenance of medical records for use by medical mission groups in Central America. As a child's information is entered into the DB, I want to be able to display his growth progress percentile numerically instead of graphically as found on a standard CDC.gov weight vs height growth chart. The graph are nonlinear so I just can't use an expression.

I have the data for percentiles based on weight and height but I need to be able to find the CLOSEST value on this table to the child's observed values of height and weight.

How do I find the value on a table which is closest to a specified number?

View 6 Replies View Related

Queries :: Finding Names That Appear More Than Once In A Table?

Jul 29, 2013

I have a table with associate names and rankings for each month. I need some way to find out which associates appear in 2 consecutive months with a certain rating. I have a query that will allow you to key in which month you want to look at, but I can't figure out how to write the query to return results only for those associates that appear twice in the months chosen. For example:

John Doe was rated 1.5 in May and 3 in June.
Jane Doe was rated a 1.5 in May and 1.5 in June.

I want a query that will allow me to put in May and June as the criteria as well as < 2 for the rating and only return those that show in both months...

View 5 Replies View Related

Finding Last Record In A Table / Form

Jul 18, 2012

Product Name
Start Weight
End Weight

Product 1
379000
389000

Product 2
288435
226710

Product 3
699000
318882

Product 4
36800
50000

Product 5
89180
117280

Product 6
132000
132000

Product 7
18
18

Product 1

Product 2

Product 3

Product 4

Product 5

Product 6

Product 7

View 3 Replies View Related

Finding Unique Records In A Table

Mar 25, 2015

I have one table with 250 fields and hundreds of records. Each field represents a computer we have and the records in that field represent the type of applications we have on that computer. So the table looks like this:

Computer 1..........Computer 2.......... Computer 3........ Computer 250

Microsoft...............Google.................... .Paint.....................Microsoft
Windows Hotfix......Security Updates.......Java ......................Google
Java.....................Mediaplayer.............. Google.....................Java

As you can see, most computers have the same applications, but some have applications that others do not. I just need the list of applications we have from all computers. Meaning each app is listed only once.

I just need each application listed once. So I was trying to come up with a way to delete all the duplicates or use a Totals query to group the apps but since my table has 250 columns I'm not really sure how to go about it. What kind of query would be best to make this work?

View 3 Replies View Related

Create Table From Truncated Info From Other Table

Oct 20, 2006

I'm a relative newbie to the more advanced features available to Access.

If someone could help me or point me in the right direction, I'd really appreciate it.

I have one table that contains companies and associated contact info. Each company can have more than one unique number ID (3 digit alphanumeric).

I want to take this table and run a query to create a new table that will only have one instance of each company name, along with the other contact information. The unique ID's aren't needed in this table (but it would be great if I could somehow toss them in, too).

This new table would then be used to create a form with a combo box containing all of the names to quickly jump to their contact info.

Any and all help would be appreciated. If a query isn't the best avenue for this, then please point me in that direction, too.

Thanks!

View 5 Replies View Related

Getting Table Info From Another DB

May 13, 2005

Guys i have tried to seach the Forum but can't find a solution to my need.

I would like to get a collection of table names from another DB, what i am trying to do is populate a table with a list of table names that the front end links to and their paths once a user has selected the data file location.

Instead of me having to force a user to place the DB files in a location of my choice when the database first loads it will prompt the user to select the location of the data file then (this is why i need the above) populate a table with a list of table names and their source, then establish a link to them for the front end to work.

Also if i ever send amended DB files or they move the location of the data files they can automatically re-establish the linked tables.

Hope this makes sense.

Cheers guys.

View 3 Replies View Related

Finding Duplicate Values From The Table Having No Primary Key

May 18, 2005

Hi All,

I have one table where ID field is autogenerated, and another field orderno which is not primary key. Now it has 2 duplicate values in it so when I try to make field Orderno as primary key, it is not allowing me to do so.

Can any one help me how to find the duplicate values using query.

Thanks in advance,

Jigs

View 1 Replies View Related

Finding Digits In Text And Link Them With Value Of Another Table?

Jan 5, 2014

I have a table where there is information stored about certain workorders.. like location, description, etc.

The thing is that location is descripted as "03-LZ-.." where the 03 part stands for the departement. I have another table with all the numbers and departements and now I'm looking for a way to link the two. So I have to find a way to look at the first to digits of the "location" in my workorder table and link that number with the table where numbers and departements are stored.

View 2 Replies View Related

Getting Existing Info To Different Table (same Db)

Aug 8, 2005

I have an inventory table and a repair table for computer equipment. The inventory table is already set and working with all the data I need.

In the repair table, I would like to just enter the ID number and have some of the information already stored in the inventory table automatically entered into the repair table as needed.

For example, computer 138 has repairs done to it. I would like to then go into the repair table to add a new entry, type in 138 and have the some of the data from inventory table (model, serial number, etc) transfer into the repair table.

Is this possible with Access?

I have only been able to do something with the lookup wizard, but that doesnt seem to work well.

Can anyone point me in the right direction?

View 1 Replies View Related

Getting Info From Combo Box To Table

Sep 19, 2004

I have managed to get one combo box on a form (Categories) to look up the approprate values for that category and populate another combo box, i.e. if I choose Premesis costs in the categories combo box, I am given the relevant choices in the Details combo box, eg. rent, cleaning...

Now this is all great but I want the values I select in BOTH boxes to be entered into the underlying table. I have tried putting the relevant field as the control source, but the way it is set up means that only numbers are put into the table. Here is the code and stuff (I got this from a help site, so I have changed my table and control name to theirs to make life a bit easier):

cboStore (i.e. the Categories)
Row Source: SELECT tblStore.lngStoreID, tblStore.strStoreName FROM tblStore;

Event - AfterUpdate:

Private Sub cboStore_AfterUpdate()
Dim sManagerSource As String

sManagerSource = "SELECT [tblManager].[lngManagerID], [tblManager].[lngStoreID], [tblManager].[strManagerName] " & _
"FROM tblManager " & _
"WHERE [lngStoreID] = " & Me.cboStore.Value
Me.cboManager.RowSource = sManagerSource
Me.cboManager.Requery
End Sub
Private Sub Label5_Click()
DoCmd.OpenQuery "qryCategories", , acReadOnly
End Sub

cboManager (i.e. Details)
Row Source: SELECT tblManager.lngManagerID, tblManager.lngStoreID, tblManager.strManagerName FROM tblManager;

The Tables:
tblStore: Field names: ingStoreID (Autonumber); strStoreName (text)
tblManager: Field Names: ingManagerID (Autonumber); ingStoreID (Number); strManagerName (text)

The Query (very simple):
qryCategories: strManagerName From tblManager; strStoreName from tblStore.


Phew! Is that enough info for someone to help me? I wouldn't mind even the numbers being in the table if there was some way that I could change them back to text for a report.

I'd be really greatful if someone out there could help - be gentle with me though, as I'm note very good at this code thing!

View 2 Replies View Related

Duplicate Info In Table

Dec 14, 2004

I've got a huge table with one column that shows a lot of duplicate
info in it. How can I let it identify the unique names and "hide" all the
duplicate info that falls under it e.g.

Columns:
Col.1:Fruit Col.2 Col.3
Apples A 1
Pears B 2
Peach C 3
Apples D 4
Apples
Apples
Pears
Pears
Pears

I would like the table only to show the say Fruit column with Apple, Pears,Peach
and list when you click on it all the related data to it. Along with this I would like to
associate all this info in the form. If I select Fruit in the form the related data should appear
below in maybe a subtable or something which I should be able to select from which info I need.

View 4 Replies View Related

Info From Form On Table

Mar 27, 2008

I know there should be a simple solution to this problem but i have not worked on access for some time and the cobwebs is too thick.

I have 2 tables one being Stock codes with related fields: Stock code id; Stock code;length;width;height.

Second table is Order Details with related fields: ID; Order id; Stock code;quantity;length;width;;height.

Did a query running the stock codes with length width and height.

Did a form with all details, calling up the stock codewith the query. The info on length width and height to the related stock code is on the form but how do i relate it back to the table Order details.

In the order details table the stock code is showing but none of the other related info.

As i said it is something small but i cant get round it.

View 3 Replies View Related

Filtering Down Table Info

Jan 15, 2006

I have a table that lists all of my available seating for different events.

My table columns look like this:
EventID - Section - Row - Seat - Available

Sample data in columns:
1 - A - A - 1 - Y
1 - A - A - 2 - Y
1 - B - A - 1 - N
1 - B - A - 2 - Y
2 - A - A - 1 - Y
2 - A - A - 2 - Y
2 - B - A - 1 - Y
2 - B - A - 2 - Y

EventID actually goes from 1-6
Section actually goes from A-F
Row actually goes from A-J
Seat actually goes from 1-36

When the user selects an event (or events) in the first box - I would like the query to eliminate the available seating, from the other events, in the results.

When the user selects a section (or sections) - I would like the query to further eliminate the available seating, from sections not chosen, in the results.

When the user selects a row (or rows) - I would like the query to further eliminate the available seating, from rows not chosen, in the results. And finally display whatever available seating is available - based on all three of the above criteria.

I purchased every access book I could find.. and I am slowly learning this. I'm a complete novice..
I'm not looking for any of you to do the work for me.. I'm more looking for guidence. I'm still getting to know all of the controls and their limitations. I have not yet written any VBA code. (It's still very confusing) I'm trying to get by on using the toolbox controls, using queries, macros and form controls.

View 2 Replies View Related

Finding The Source Of A Linked Table To A Front End Database

Dec 17, 2004

I have been working on quite a few multi user Access projects in the past few months with a backend and a front end which has linked tables.

I would like to know if there is any way to find out the source of a table linked to the front end and where would its location be on the network.

View 3 Replies View Related

Queries :: Calls Table - Finding Last Contact Date

Aug 7, 2014

There are three tables. An [Action Register] table, a [Calls] table and a [tblContacts] table. The Contacts are common to both.

The Calls table records calls to customer by date

The Action Register table records issues that Customers send in by Open date.

I am trying to make a query where we see the latest date the customer was contacted regardless of which table.

I created two queries.

qryLastCallDate finds the max date from the Call table:

SELECT Max(Calls.CallDate) AS MaxOfCallDate, tblContacts.ContactName
FROM Calls LEFT JOIN tblContacts ON Calls.ContactID = tblContacts.ContactID
GROUP BY tblContacts.ContactName
ORDER BY Max(Calls.CallDate);

qryLastIssueDate finds the max date from the Action Register table:

SELECT Max([Action Register].Open) AS MaxOfOpen, tblContacts.ContactName
FROM tblContacts RIGHT JOIN [Action Register] ON tblContacts.ContactID = [Action Register].Contact
GROUP BY tblContacts.ContactName
ORDER BY Max([Action Register].Open);

The problem I am having is that if I use Left Join I can see all the records from the Calls table but not all from the Action Register table. And vis versa if I use Right Join. This is because sometimes we have calls but no issues in the Action Register table and sometimes issues with no calls.

This is my Left Join query using a Min Max Module I found here: [URL] ....

SELECT qryLastCallDate.ContactName, qryLastCallDate.MaxOfCallDate, qryLastIssueDate.MaxOfOpen, qryLastIssueDate.ContactName, DateValue(MaxOfList([MaxOfCallDate],[MaxOfOpen])) AS [Last Contact], ([Last Contact]+21) AS NextCall
FROM qryLastCallDate LEFT JOIN qryLastIssueDate ON qryLastCallDate.ContactName = qryLastIssueDate.ContactName;

How do I get to see ALL the records from both queries.

View 3 Replies View Related

Tables :: Finding Specific Record In A Linked Table

Jun 19, 2013

From what I have read, I understand you can't use the seek command on a recordset from a linked table from another database. Is that true? If so, what is the alternative to find a specific record in the table using an indexed field?

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved