5

これを試して

select tblPersonalInfo.companyname, tblJobBudget.title,tblJobBudget.lastmodifiedby,
tblJobAdv.advtitle, tblJobAdv.userId,       
tblApplication.advid, tblApplication.position
from tblJobAdv 
inner join tblApplication
ON tblJobAdv.advid = tblApplication.advid
inner join tblPersonalInfo
On tblJobBudget.lastmodifiedby = tblPersonalInfo.userid

エラーが発生します

Msg 4104, Level 16, State 1, Line 8
The multi-part identifier "tblJobBudget.lastmodifiedby" could not be bound.
Msg 4104, Level 16, State 1, Line 2
The multi-part identifier "tblJobBudget.title" could not be bound.
Msg 4104, Level 16, State 1, Line 2

マルチパート識別子「tblJobBudget.lastmodifiedby」をバインドできませんでした。

4

1 に答える 1

5

tblJobBudgetこれは、識別子を持つテーブルまたはテーブルエイリアスがないためです。

テーブルは次のとおりです。

  • tblJobAdv
  • tblApplication
  • tblPersonalInfo

だがしかし:

  • tblJobBudget

テーブルの列が必要な場合は、次の句を使用してテーブルにtblJobBudget含める必要があります。tblJobBudgetjoin

from       tblJobAdv 
inner join tblApplication
   ON tblJobAdv.advid = tblApplication.advid
inner join tblJobBudget                              <--here
   ON ...
inner join tblPersonalInfo
   ON ...
于 2012-12-29T14:42:55.820 に答える