Solved

Access ADO error: The multi-part identifier could not be bound

Posted on 2009-04-05
3
509 Views
Last Modified: 2012-05-06
Hi,
  I have a pivot chart in my Access project file. My record souce of the form looks like below:

Select Customer_Id, Customer_Name, Order_Date
FROM  Orders INNER JOIN Customers
On Orders.Customer_Id = Customers.Customer_Id
WHERE Orders.Order_Type = ? AND Customers.Region = ?

It throws the below error:
-------------------------
ADO Error: The multi-part identifier "Orders.Order_Type" could not be bound...
-------------------------

If I have only one where clause, then it works
Select Customer_Id, Customer_Name, Order_Date
FROM  Orders INNER JOIN Customers
On Orders.Customer_Id = Customers.Customer_Id
WHERE Orders.Order_Type = ?

(or)

Select Customer_Id, Customer_Name, Order_Date
FROM  Orders INNER JOIN Customers
On Orders.Customer_Id = Customers.Customer_Id
WHERE Customers.Region = ?

How to solve this?
0
Comment
Question by:xsysys
  • 2
3 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 125 total points
ID: 24074603
try this:
Select Customer_Id, Customer_Name, Order_Date 
FROM  Orders INNER JOIN Customers 
On ( Orders.Customer_Id = Customers.Customer_Id AND Customers.Region = ? )
WHERE ( Orders.Order_Type = ?  )

Open in new window

0
 

Author Comment

by:xsysys
ID: 24074696
I changed my sql as per your feedback. Now it displays the error twice.
 
-----
ADO Error: The multi-part identifier "Orders.Order_Type" could not be bound...
                   The multi-part identifier "Orders.Order_Type" could not be bound...  
-----
in a single message...
 
What to do next?
 
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 24074820
can you please show the relevant code that you use to run the query, please?
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Suggested Solutions

It took me quite some time to sort out all the different properties of combo and list boxes available from Visual Basic at run-time. Not that the documentation is lacking: the help pages are quite thorough and well written. The problem was rather wh…
QuickBooks® has a great invoice interface that we were happy with for a while but that changed in 2001 through no fault of Intuit®. Our industry's unit names are dictated by RUS: the Rural Utilities Services division of USDA. Contracts contain un…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

759 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

18 Experts available now in Live!

Get 1:1 Help Now