--Here is my total append query in Access:
INSERT INTO dbo_TempCompDutData ( DutSerialNumber, StationId,
RunNumber, DutInfo1, DutInfo2, DutInfo3, DutUniversalRevision,
DutSpecificRevision, DutSoftwareRevision, DutHardwareRevision, DutTag,
Oven, Rack, Channel, Calibrator, CalibratorDue, Resistor, ResistorDue,
CompPassed, VerifyPassed, FinalCalPassed, Passed, Notes )
SELECT TempCompDutData.DutSerialNumber, TempCompDutData.StationId,
TempCompDutData.RunNumber, TempCompDutData.DutInfo1,
TempCompDutData.DutInfo2, TempCompDutData.DutInfo3,
TempCompDutData.DutUniversalRevision,
TempCompDutData.DutSpecificRevision,
TempCompDutData.DutSoftwareRevision,
TempCompDutData.DutHardwareRevision, TempCompDutData.DutTag,
TempCompDutData.Oven, TempCompDutData.Rack, TempCompDutData.Channel,
TempCompDutData.Calibrator, TempCompDutData.CalibratorDue,
TempCompDutData.Resistor, TempCompDutData.ResistorDue,
TempCompDutData.CompPassed, TempCompDutData.VerifyPassed,
TempCompDutData.FinalCalPassed, TempCompDutData.Passed,
TempCompDutData.Notes
FROM TempCompDutData;
--dbo_TempCompDutData is a linked table in Access, to the SQL table.
--TempCompDutData is the Access Table.
--Here is the total structure of the SQL Server 2000 table:
CREATE TABLE [TempCompDutData] (
[DutDataId] [int] IDENTITY (1, 1) NOT FOR REPLICATION NOT NULL ,
[DutSerialNumber] [int] NOT NULL ,
[StationId] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[RunNumber] [int] NOT NULL ,
[DutInfo1] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
,
[DutInfo2] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
,
[DutInfo3] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
,
[DutUniversalRevision] [int] NULL ,
[DutSpecificRevision] [int] NULL ,
[DutSoftwareRevision] [int] NULL ,
[DutHardwareRevision] [int] NULL ,
[DutTag] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
[Oven] [int] NULL ,
[Rack] [int] NULL ,
[Channel] [int] NULL ,
[Calibrator] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS
NULL ,
[CalibratorDue] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS
NULL ,
[Resistor] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
,
[ResistorDue] [nvarchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS
NULL ,
[CompPassed] [int] NULL ,
[VerifyPassed] [int] NULL ,
[FinalCalPassed] [int] NULL ,
[Passed] [int] NULL ,
[Notes] [ntext] COLLATE SQL_Latin1_General_CP1_CI_AS NULL ,
CONSTRAINT [PK_tblTempCompDutData] PRIMARY KEY CLUSTERED
(
[DutSerialNumber],
[StationId],
[RunNumber]
) WITH FILLFACTOR = 80 ON [PRIMARY] ,
CONSTRAINT [FK_TempCompDutData_TempCompRunData] FOREIGN KEY
(
[StationId],
[RunNumber]
) REFERENCES [TempCompRunData] (
[StationId],
[RunNumber]
) ON DELETE CASCADE ON UPDATE CASCADE
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
I am not sure how to discribe the Access table other than it is
supposed to mirror the SQL table....
Tony Toews said:
Is there another field on the SQL Server database which has a unique
index attribute set? Or combination of fields?
Tony