G
Gary Nelson
In Access2000, backend SQL - I have code that I am attempting to save after
making a change. However, I am receiving an error message stating ADO
error: Ambiguous Column Name 'Bound Book'.
The Due Date code is the code I've changed and attempting to save. The
stored procedure is below. Can you please offer assistance as to what I
need to do in order to save without the error?
----------------------------------------------------------------------------
--------------------------
Alter PROCEDURE dbo.spMasterRebinds AS
SELECT TOP 100 PERCENT dbo.BookAll.JobNum, dbo.[Binding
Style].BindStyleAbbr, dbo.BookAll.DateIn, dbo.BookAll.CustRequestDate,
dbo.[Job - ED].AgreedDate, dbo.BookAll.Author, dbo.Publisher.Publisher,
dbo.BookAll.Title, dbo.[Job - ED].dtPrintCvr, dbo.[Job - ED].dtCompMech,
dbo.BookAll.TextPgs, dbo.BookAll.TotPgs, dbo.BookAll.CustQuantity,
dbo.[Job - ED].dtPrint, dbo.[Scheduling - AD].dtShipped,
dbo.[Scheduling - AD].dtSendTxtPrf AS TextPrfDate, dbo.[Scheduling -
AD].TxtPrfStatus, dbo.[Job - ED].ScanTextDue,
dbo.[Scheduling - AD].DateScanComp, dbo.BookAll.CvrProof, dbo.[Scheduling -
AD].CvrPrfStatus, dbo.[Job - ED].dtSendCvrPrf,
dbo.[Scheduling - AD].dtSendCvrPrf AS CvrProofDate,
dbo.BookAll.PrtBeforeByIBT, dbo.[Contacts-alpha].ContactName,
dbo.[Scheduling - AD].dtSendToBndry, dbo.Publisher.CSRRep1, dbo.[IBT
Employees].NameLastFirst, dbo.BookAll.CvrPrntProcessID,
dbo.[Rework Expense].JobNumOriginal, dbo.[Scheduling - AD].dtBound,
dbo.[Scheduling - AD].dtFandGs, dbo.BookAll.FandGTypeID,
dbo.[Hot Jobs].HotJob, dbo.BookAll.NumBWInserts,
dbo.BookAll.NumColorInserts, dbo.[Scheduling - AD].FandGStatus,
dbo.[Scheduling - AD].dtDiestoIBT, dbo.tblHoldJobs.Hold,
dbo.BookAll.PrintCode, dbo.BookAll.HoleDrilling, dbo.BookAll.Jacketing,
dbo.BookAll.AdhereDisk, dbo.BookAll.AdhereBarCodeCvr, dbo.[Scheduling -
AD].dtLaminationComp, dbo.[Scheduling - AD].dtInsertsprint,
dbo.[Scheduling - AD].dtColorInsertsPrint, dbo.BookAll.InsertProof,
dbo.[Scheduling - AD].dtSendLastProof, dbo.[Scheduling -
AD].dtSendFinalCvrProof,
dbo.BoundDue.BoundBook, dbo.BoundBook.BoundBook AS Expr1,
dbo.[Scheduling-LoadedDates].TextProofDue,
dbo.[Scheduling-LoadedDates].PrintTextDue,
dbo.[Scheduling-LoadedDates].CoverProofDue,
dbo.[Scheduling-LoadedDates].PrintCoverDue,
dbo.[Scheduling-LoadedDates].APKBindingDue,
dbo.[Scheduling-LoadedDates].SendToBNB,
dbo.[Scheduling-LoadedDates].LoadedDate,
dbo.BookAll.TextVolNum, dbo.BookAll.TextEditionIssueNum, dbo.BookAll.CatNum,
dbo.BookAll.CatLabel, dbo.[Scheduling - AD].dtPrintTxt2,
dbo.[Job - ED].DaysAdded, dbo.[Scheduling - AD].dtBound2,
dbo.BookAll.ShrinkWrap, LamMatID,dbo.BookAll.JobDescriptor,
'Duedate' =
CASE
WHEN Hold = 1 THEN '9/9/99'
WHEN (CustomerDelay = 0 or CustomerDelay is Null) and (CustRequestDate <
BoundBook) THEN BoundBook
WHEN CustomerDelay = 1 and [Take Off Hold] = 1 and CustRequestDate <
(BoundBook + DaysOnHold) THEN (BoundBook + DaysOnHold)
ELSE CustRequestDate
END,
making a change. However, I am receiving an error message stating ADO
error: Ambiguous Column Name 'Bound Book'.
The Due Date code is the code I've changed and attempting to save. The
stored procedure is below. Can you please offer assistance as to what I
need to do in order to save without the error?
----------------------------------------------------------------------------
--------------------------
Alter PROCEDURE dbo.spMasterRebinds AS
SELECT TOP 100 PERCENT dbo.BookAll.JobNum, dbo.[Binding
Style].BindStyleAbbr, dbo.BookAll.DateIn, dbo.BookAll.CustRequestDate,
dbo.[Job - ED].AgreedDate, dbo.BookAll.Author, dbo.Publisher.Publisher,
dbo.BookAll.Title, dbo.[Job - ED].dtPrintCvr, dbo.[Job - ED].dtCompMech,
dbo.BookAll.TextPgs, dbo.BookAll.TotPgs, dbo.BookAll.CustQuantity,
dbo.[Job - ED].dtPrint, dbo.[Scheduling - AD].dtShipped,
dbo.[Scheduling - AD].dtSendTxtPrf AS TextPrfDate, dbo.[Scheduling -
AD].TxtPrfStatus, dbo.[Job - ED].ScanTextDue,
dbo.[Scheduling - AD].DateScanComp, dbo.BookAll.CvrProof, dbo.[Scheduling -
AD].CvrPrfStatus, dbo.[Job - ED].dtSendCvrPrf,
dbo.[Scheduling - AD].dtSendCvrPrf AS CvrProofDate,
dbo.BookAll.PrtBeforeByIBT, dbo.[Contacts-alpha].ContactName,
dbo.[Scheduling - AD].dtSendToBndry, dbo.Publisher.CSRRep1, dbo.[IBT
Employees].NameLastFirst, dbo.BookAll.CvrPrntProcessID,
dbo.[Rework Expense].JobNumOriginal, dbo.[Scheduling - AD].dtBound,
dbo.[Scheduling - AD].dtFandGs, dbo.BookAll.FandGTypeID,
dbo.[Hot Jobs].HotJob, dbo.BookAll.NumBWInserts,
dbo.BookAll.NumColorInserts, dbo.[Scheduling - AD].FandGStatus,
dbo.[Scheduling - AD].dtDiestoIBT, dbo.tblHoldJobs.Hold,
dbo.BookAll.PrintCode, dbo.BookAll.HoleDrilling, dbo.BookAll.Jacketing,
dbo.BookAll.AdhereDisk, dbo.BookAll.AdhereBarCodeCvr, dbo.[Scheduling -
AD].dtLaminationComp, dbo.[Scheduling - AD].dtInsertsprint,
dbo.[Scheduling - AD].dtColorInsertsPrint, dbo.BookAll.InsertProof,
dbo.[Scheduling - AD].dtSendLastProof, dbo.[Scheduling -
AD].dtSendFinalCvrProof,
dbo.BoundDue.BoundBook, dbo.BoundBook.BoundBook AS Expr1,
dbo.[Scheduling-LoadedDates].TextProofDue,
dbo.[Scheduling-LoadedDates].PrintTextDue,
dbo.[Scheduling-LoadedDates].CoverProofDue,
dbo.[Scheduling-LoadedDates].PrintCoverDue,
dbo.[Scheduling-LoadedDates].APKBindingDue,
dbo.[Scheduling-LoadedDates].SendToBNB,
dbo.[Scheduling-LoadedDates].LoadedDate,
dbo.BookAll.TextVolNum, dbo.BookAll.TextEditionIssueNum, dbo.BookAll.CatNum,
dbo.BookAll.CatLabel, dbo.[Scheduling - AD].dtPrintTxt2,
dbo.[Job - ED].DaysAdded, dbo.[Scheduling - AD].dtBound2,
dbo.BookAll.ShrinkWrap, LamMatID,dbo.BookAll.JobDescriptor,
'Duedate' =
CASE
WHEN Hold = 1 THEN '9/9/99'
WHEN (CustomerDelay = 0 or CustomerDelay is Null) and (CustRequestDate <
BoundBook) THEN BoundBook
WHEN CustomerDelay = 1 and [Take Off Hold] = 1 and CustRequestDate <
(BoundBook + DaysOnHold) THEN (BoundBook + DaysOnHold)
ELSE CustRequestDate
END,