Solved

The multi-part identifier <Identifier> could not be bound

Posted on 2007-11-17
1
422 Views
Last Modified: 2008-02-01
Hello,

I'm trying to update one table column with the values in another table's column of the same name.  I'm getting the error:

The multi-part identifier "Gifts.Gift_ID" could not be bound.

This is the query:

UPDATE Gifts
SET Gifts.Received=(SELECT RECIPIENTS_GIVERS_TO_GIFTS.RECEIVED
                              FROM RECIPIENTS_GIVERS_TO_GIFTS
                              WHERE Gifts.Gift_ID=RECIPIENTS_GIVERS_TO_GIFTS.Gift_ID)

The "Gift_ID" is causing a problem in both tables, depending how I word the query.  This must have something to do with the ID key and foreign key relationship.  At this point, I'm only executing the sub-query, so the outlying query is not in play.

The GIFT_ID field in both tables is a smallint.

Any ideas?
0
Comment
Question by:NigelRocks
1 Comment
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 500 total points
ID: 20306491

UPDATE G
SET Received=rg.RECEIVED
FROM Gifts g
INNER JOIN  RECIPIENTS_GIVERS_TO_GIFTS rg
ON G.Gift_ID=RG.Gift_ID
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

744 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

13 Experts available now in Live!

Get 1:1 Help Now