473,396 Members | 1,834 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Expression Builder - Access 2003

I have a 2003 Access Database with several tables related in a one to many relationship with a parent I am looking to build a report which evaluates if different users of the table have all entered data properly.

As an example - the parent table creates the customer account number, customer last name and customer ssn. A related table creates all other customer information including address, phone etc., another related table contains information researched on the customer

I am new to expressions but have determined if I wish to conpare two fields from 2 separate tables that should contain the same information, (however the field names are different), I think I would use the if-then-else expression below.

I have built a query with the parent and both tables and used the criteria line in the table A field 1 column to place the expression. I have also tried to move the expression to a new column which creates Expr1: - both have not returned the appropriate responses.

I have also tried building the expression into a control on the report itself separate from the query with no success.

IIf([tableA.field1]=[tableB.field2], "field match", "field input error")

(I am using the expression builder - not skilled in code yet) - any suggestions?
Nov 1 '06 #1
3 10352
MMcCarthy
14,534 Expert Mod 8TB
SELECT ParentTable.Field1,
IIf([ParentTable.field1]=[tableA.field2], "field match", "field input error") As TableAMatch, IIf([ParentTable.field1]=[tableB.field2], "field match", "field input error") As TableBMatch
FROM ((ParentTable LEFT JOIN TableA
ON ParentTable.Field1=TableA.Field2)
LEFT JOIN TableB ON ParentTable.Field1=TableB.Field2)


Try something like this ....
Nov 1 '06 #2
SELECT ParentTable.Field1,
IIf([ParentTable.field1]=[tableA.field2], "field match", "field input error") As TableAMatch, IIf([ParentTable.field1]=[tableB.field2], "field match", "field input error") As TableBMatch
FROM ((ParentTable LEFT JOIN TableA
ON ParentTable.Field1=TableA.Field2)
LEFT JOIN TableB ON ParentTable.Field1=TableB.Field2)


Try something like this ....
Thanks - where would I attach this statement - to a text box control in a report or to a new column in a query or to a criteria line in a column - trying to stay within boundaries of my knowledge of access expression builder feature/wizard

again - thanks
Nov 2 '06 #3
MMcCarthy
14,534 Expert Mod 8TB
Thanks - where would I attach this statement - to a text box control in a report or to a new column in a query or to a criteria line in a column - trying to stay within boundaries of my knowledge of access expression builder feature/wizard

again - thanks
I meant for you to use this as the Record Source for a new report which is what you said you wanted.
Nov 2 '06 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Grant Hammond | last post by:
I assume I'm not alone in my frustration that the expression builder that comes (in part) with Access XP that dosnt wrap text when you open it on an exisitng expression in a query or form. I's...
0
by: JMCN | last post by:
hi- this function IDSpecialCases works great in access 97 in the query builder but why doesn't it work in access 2003? would does anyone have any wild guesses? is it a problem with the dao...
1
by: Laertes | last post by:
Hi, I want to use the expression builder in a query to define a field. I know how to do it for simple fields, like the one below : orderdate: IIf((IsNull() And =False) Or (<>"N/A" And...
3
by: X_HOBBES | last post by:
I'm fairly new to Access, let alone Expression Builder. However, it seems that I'm either doing something really wrong or Access is really stupid! I can't reference fields that show up on my...
2
by: Mike Turco | last post by:
I like using the expression builder for a lot of different things but it isn't always available when I want to use it, for example in the code window, or in all of the control properties. I am...
0
by: AlexanderTodorovic | last post by:
Hello Everyone, I'm developing a client application in which the users need an expression builder as provided in MS Access 2003. I would like to use the expression builder in a C# application....
14
by: pdavis06 | last post by:
I know that there is a thread about this, but I was unable to add to it; I just joined. The problem is that I do not want to change the date format for the entire database output, merely for a header...
18
by: emajka21 | last post by:
Access 2000, I am trying to add a "Summed" total to a report (in a grouped footer section). But I only want to sum the top 3 items. I know how to write this in sql but it seems I can't get a to a...
1
by: KerryA | last post by:
Hi, I am trying to create a report on a table I have set up called ‘Outcomes’. I need to be able to do a count of all fields that have said ‘1’ ‘2’ or ‘3’ within a field name called ‘All outcomes’. I...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.