The concept:
I have two separate SQL 2K databases: DBA & DBB. A current VB app updates a column in table1 in DBA via a SP. I need to write a SP that will update the same column in table1 in DBB. The SP will be triggered on a timed basis by an external piece of hardware and will look for:
DBA-Table1-key1 = DBB-Table2-key1
DBA-Table1-stat1<>DBB-Table2-stat2 then
SET DBB-Table2-stat2=DBA-Table1-Stat1
The actual implementation using actual names:
(DBA would local DB, DBB would be CR_IT_A)
What I tried so far
The error message I received
The number name 'CR_IT_A.Production.dbo.Table1' contains more than the maximum number of prefixes. The maximum is 3.
Can someone give me some guidance as to what I am missing?
I have two separate SQL 2K databases: DBA & DBB. A current VB app updates a column in table1 in DBA via a SP. I need to write a SP that will update the same column in table1 in DBB. The SP will be triggered on a timed basis by an external piece of hardware and will look for:
DBA-Table1-key1 = DBB-Table2-key1
DBA-Table1-stat1<>DBB-Table2-stat2 then
SET DBB-Table2-stat2=DBA-Table1-Stat1
The actual implementation using actual names:
(DBA would local DB, DBB would be CR_IT_A)
What I tried so far
Code:
update [CR_IT_A].[Production].dbo.Table1
set [CR_IT_A].[Production].dbo.Table1.status = dbo.Table1.status
where (([CR_IT_A].[Production].dbo.Table1.status = dbo.Table1.status) and
([CR_IT_A].[Production].dbo.Table1.rotation_num = dbo.Table1.rotation_num))
The error message I received
The number name 'CR_IT_A.Production.dbo.Table1' contains more than the maximum number of prefixes. The maximum is 3.
Can someone give me some guidance as to what I am missing?