• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 196
  • Last Modified:

T-SQL

I get the error. I checked the table which is having the fields ....

Msg 207, Level 16, State 3, Line 1
Invalid column name 'Futureyear1amount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'Futureyear2amount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'Futureyear3amount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'Futureyear4amount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'Futureyear5amount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'AwardedTotalCostAmount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'TotalObligatedAmount'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'FULLGrantnumber'.
Msg 207, Level 16, State 3, Line 1
Invalid column name 'FY'.

Update F
SET 
FY = V.FY,
Futureyear1amount = V.Futureyear1amount,
Futureyear2amount = V.Futureyear2amount ,
Futureyear3amount = V.Futureyear3amount ,
Futureyear4amount = V.Futureyear4amount ,
Futureyear5amount = V.Futureyear5amount ,
AwardedTotalCostAmount = V.AwardedTotalCostAmount ,
ObligatedTotalCostAmount = V.TotalObligatedAmount 
 
FROM GrantsFMB F
INNER JOIN
(SELECT 
Futureyear1amount,
Futureyear2amount ,
Futureyear3amount ,
Futureyear4amount ,
Futureyear5amount ,
AwardedTotalCostAmount ,
TotalObligatedAmount 
) V
 
ON F.FULLGrantnumber = V.FULLGrantnumber
AND
F.FULLGrantnumber in 
('1F30NS064624-01',
'1F30NS064626-01', 
'1F31NS063514-01A1', 
'1F32NS064775-01', 
'2R01NS026539-22',
'2R01NS048425-05A1', 
'3P50NS044148-06S1',
'3P50NS044283-06S1', 
'3R01NS028785-21S1', 
'3R01NS034950-16A2S1', 
'3R01NS039996-08S1', 
'3R01NS050446-03S1',
'3R01NS050597-03S1', 
'3R01NS054780-03S1',
'3R01NS057366-01A2S1', 
'3R01NS057464-01A2S1', 
'3SC2NS065385-01S1', 
'3U54NS060659-01S1', 
'5R42NS055606-03', 
'7U01NS051566-04', 
'2R01NS050266-06')

Open in new window

0
priyasarav
Asked:
priyasarav
  • 3
  • 2
1 Solution
 
chapmandewCommented:
you're not selecting from a table here:

SELECT
Futureyear1amount,
Futureyear2amount ,
Futureyear3amount ,
Futureyear4amount ,
Futureyear5amount ,
AwardedTotalCostAmount ,
TotalObligatedAmount

0
 
priyasaravAuthor Commented:
Yeah. I fixed it myself ... Thanks for your help anyway
0
 
chapmandewCommented:
why the B answer?
0
 
priyasaravAuthor Commented:
Just because your were able to find the solution .. why you need 'A' :) i can do that if i can edit it ...
0
 
priyasaravAuthor Commented:
Hi Admin,

Can you make it very clear what you are trying to say ....

The answer he gave me was precise to what am looking for...but i found the answer myself ....

Thats the reason why i gave 'B' grade for it ...

I could have given hime 'A' but the question was not  that difficult

PS: Let me know if you trying to communicate anything to me ...

Also when grading timing should also be factored

regards
sarav
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now