Update query question

T

troy

I have a query with the following SQL..

UPDATE (dbo_tblSaaDocument INNER JOIN (dbo_tblObligationType INNER JOIN
(dbo_TblProduct INNER JOIN dbo_TblProductVersion ON dbo_TblProduct.ProductId
= dbo_TblProductVersion.ProductId) ON dbo_tblObligationType.ObligationTypeID
= dbo_TblProduct.ObligationTypeID) ON dbo_tblSaaDocument.SaaDocumentID =
dbo_tblObligationType.SaaDocumentID) LEFT JOIN DEV_dbo_TblProduct ON
dbo_TblProduct.ProductId = DEV_dbo_TblProduct.ProductId SET
DEV_dbo_TblProduct.Description = dbo_TblProductVersion.description,
DEV_dbo_TblProduct.StateAbbr = dbo_TblProduct.stateabbr,
DEV_dbo_TblProduct.BondType = dbo_tblObligationType.bondtype,
DEV_dbo_TblProduct.CategoryId = dbo_tblObligationType.categoryid,
DEV_dbo_TblProduct.FormId = dbo_TblProductVersion.newbusinessFormID,
DEV_dbo_TblProduct.RateType = dbo_TblProductVersion.ratetype,
DEV_dbo_TblProduct.ObligeeId = dbo_TblProduct.obligeeid,
DEV_dbo_TblProduct.RenewalMethod = dbo_TblProductVersion.renewalmethod,
DEV_dbo_TblProduct.BondEffectiveDate =
dbo_TblProductVersion.bondeffectivedate,
DEV_dbo_TblProduct.BondExpirationDate =
dbo_TblProductVersion.bondexpirationdate, DEV_dbo_TblProduct.BondTermMonths =
dbo_TblProductVersion.bondtermmonths, DEV_dbo_TblProduct.BondAmtStd =
dbo_TblProductVersion.bondamtstd, DEV_dbo_TblProduct.BondAmtMin =
dbo_TblProductVersion.bondamtmin, DEV_dbo_TblProduct.BondAmtMax =
dbo_TblProductVersion.bondamtmax, DEV_dbo_TblProduct.CancelDays =
dbo_TblProductVersion.canceldays, DEV_dbo_TblProduct.ClassCode =
dbo_tblSaaDocument.classcode, DEV_dbo_TblProduct.SpecialInstructions =
dbo_TblProductVersion.specialinstructions,
DEV_dbo_TblProduct.BondObligationDescription =
dbo_TblProduct.BondObligationDescription, DEV_dbo_TblProduct.Attachments =
IIf(dbo_TblProductVersion.Attachments=0,"N","Y"), DEV_dbo_TblProduct.RiskType
= dbo_TblProductVersion.risktype, DEV_dbo_TblProduct.EAndOFlag =
IIf(dbo_TblProductVersion.EAndOFlag=0,"","Y"),
DEV_dbo_TblProduct.MinCreditScore = dbo_TblProductVersion.mincreditscore,
DEV_dbo_TblProduct.AvailableOnline = "Y"
WHERE (((DEV_dbo_TblProduct.ProductId) Is Not Null))
WITH OWNERACCESS OPTION;

I am trying to do the following while updateding all fields but need to fix
the below two so it will work correctly. I receive all records the way it is
now. This was done by another person and it is linked to SQL backend. Can
someone help please?

1. update the "Attachment" filed if there is a Y or N added. The filed is
set up as a text filed.

2. I get a parameter popup on the AvailableOnline field. Strange just a
stright field
 
J

Jerry Whittle

2. Is AvailableOnline a text field? If not the double-quotes around the Y
could cause problems.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top