Here is the SQL for the query. Thanks for looking.
SELECT dbo_AltLoss.[Claim Number], dbo_Register.[Policy Number],
dbo_Register.[Date Entered], dbo_Register.Initials, dbo_Register.[Date
of Loss], dbo_Register.[Cause of Loss], dbo_Register.[Status of Claim],
dbo_Register.[Closed Date], dbo_Register.[Insured Name],
dbo_Register.[Insured Address], dbo_Register.[Insured City],
dbo_Register.[Insured State], dbo_Register.[Insured Zip],
dbo_Register.[Insured Phone], dbo_Register.[Insured Phone2],
dbo_Register.Location, dbo_Register.[Claimant First Name],
dbo_Register.[Claimant Last Name], dbo_Register.[Claimant Address],
dbo_Register.[Claimant City], dbo_Register.[Claimant State],
dbo_Register.[Claimant Zip], dbo_Register.[Claimant Phone],
dbo_Register.[Claimant Phone2], dbo_Register.Injury,
dbo_Register.Label, dbo_Register.[Date Claim Rcvd], dbo_Register.[Date
Report Rcvd], dbo_Register.[Date Report Not Approved],
dbo_AltLoss.[Producer Name], dbo_AltLoss.[Producer Address],
dbo_AltLoss.[Producer City], dbo_AltLoss.[Producer State],
dbo_AltLoss.[Producer Zip], dbo_AltLoss.[Producer Phone],
dbo_AltLoss.[Producer Code], dbo_AltLoss.EffDate, dbo_AltLoss.ExpDate,
dbo_AltLoss.[Contact Name], dbo_AltLoss.[Contact Address],
dbo_AltLoss.[Contact CSZ], dbo_AltLoss.[Contact Phone1],
dbo_AltLoss.[Contact Phone2], dbo_AltLoss.Authority,
dbo_AltLoss.Description, dbo_AltLoss.[Claimant DOB],
dbo_AltLoss.[Claimant SS], FormatCurrency([PersAdvInj],0) AS
[Calc-PersAdvInj], FormatCurrency([PremiseLiab],0) AS
[Calc-PremiseLiab], FormatCurrency([Medical Expense],0) AS
[Calc-Medical Expense], FormatCurrency([Deductible],0) AS
[Calc-Deductible], dbo_AltLoss.Type, dbo_AltLoss.Injury,
dbo_AltLoss.Injury1, dbo_AltLoss.[Witness Name], dbo_AltLoss.[Witness
Address], dbo_AltLoss.[Witness CSZ], dbo_AltLoss.[Witness Phone],
dbo_AltLoss.[Additional Information], dbo_AltLoss.[Reported By],
dbo_AltLoss.[Reported To], dbo_AltLoss.[DateTime Received],
FormatCurrency([OTC Deductible],0) AS [Calc-OTC Deductible],
FormatCurrency([Coll Deductible],0) AS [Calc-Coll Deductible],
dbo_AltLoss.[Other Coverage], dbo_AltLoss.[Insured Vehicle],
dbo_AltLoss.[Insured Driver], dbo_AltLoss.[Insured Phone],
dbo_AltLoss.Damage, dbo_AltLoss.LocationVeh, dbo_AltLoss.[Claimant
Vehicle], dbo_AltLoss.LocationVeh1, dbo_AltLoss.Damage1,
dbo_AltLoss.[Insurance Carrier], dbo_AltLoss.[Injured Name],
dbo_AltLoss.[Injured Name1], dbo_AltLoss.[Injured Address],
dbo_AltLoss.[Injured Address1], dbo_AltLoss.[Injured CSZ],
dbo_AltLoss.[Injured CSZ1], dbo_AltLoss.[Injured Phone],
dbo_AltLoss.[Injured Phone1], dbo_AltLoss.Veh1, dbo_AltLoss.Veh2,
dbo_AltLoss.NoInjuries, dbo_AltLoss.KindofLoss, dbo_AltLoss.[Amount of
Loss], dbo_AltLoss.Mortgagee, dbo_AltLoss.[Mortagagee Name],
dbo_AltLoss.Item5, dbo_AltLoss.Item1, dbo_AltLoss.Item2,
dbo_AltLoss.Item3, dbo_AltLoss.Item4, dbo_AltLoss.Subject1,
dbo_AltLoss.Subject2, dbo_AltLoss.Subject3, dbo_AltLoss.Subject4,
dbo_AltLoss.Subject5, FormatCurrency([Amount1],0) AS [Calc-Amount1],
FormatCurrency([Amount2],0) AS [Calc-Amount2],
FormatCurrency([Amount3],0) AS [Calc-Amount3],
FormatCurrency([Amount4],0) AS [Calc-Amount4],
FormatCurrency([Amount5],0) AS [Calc-Amount5], FormatCurrency([Ded1],0)
AS [Calc-Ded1], FormatCurrency([Ded2],0) AS [Calc-Ded2],
FormatCurrency([Ded3],0) AS [Calc-Ded3], FormatCurrency([Ded4],0) AS
[Calc-Ded4], FormatCurrency([Ded5],0) AS [Calc-Ded5], dbo_AltLoss.RC1,
dbo_AltLoss.RC2, dbo_AltLoss.RC3, dbo_AltLoss.RC4, dbo_AltLoss.RC5,
dbo_AltLoss.PropDes1, dbo_AltLoss.PropDes2, dbo_AltLoss.PropDes3,
dbo_AltLoss.PropDes4, dbo_AltLoss.PropDes5, dbo_AltLoss.Reinsurance1,
dbo_AltLoss.Explain, dbo_AltLoss.ReportType,
FormatCurrency([Bodilyinjury],0) AS [Calc-Bodilyinjury],
FormatCurrency([Bodilyinjury1],0) AS [Calc-Bodilyinjury1],
FormatCurrency([PropDam],0) AS [Calc-PropDam],
dbo_AltLoss.Reinsurance2, dbo_AltLoss.Reinsurance3,
dbo_AltLoss.Reinsurance4, dbo_AltLoss.Reinsurance5,
dbo_AltLoss.Reinsurance6,
IIf([ReportType]=1,"TELEPHONE",IIf([ReportType]=2,"WRITE-UP","")) AS
[Calc-ReportTypetext], IIf([Veh1]=1,"INSURED
VEHICLE",IIf([Veh1]=2,"CLAIMANT VEHICLE","")) AS [Calc-Veh1text],
IIf([Veh2]=1,"INSURED VEHICLE",IIf([Veh2]=2,"CLAIMANT VEHICLE","")) AS
[Calc-Veh2text], dbo_ZipCodes.CITY, dbo_ZipCodes.STATE,
IIf([NoInjuries]=0,"YES",IIf([NoInjuries]=-1,"NO"," ")) AS
CalcNoInjuriestext, IIf([Type]=1,"PD",IIf([Type]=2,"BI"," ")) AS
CalcTypeOptionstext, dbo_AltLoss.[Witness Name2], dbo_AltLoss.[Witness
Address2], dbo_AltLoss.[Witness CSZ2], dbo_AltLoss.[Witness Phone2],
dbo_AltLoss.[Witness Name3], dbo_AltLoss.[Witness Address3],
dbo_AltLoss.[Witness CSZ3], dbo_AltLoss.[Witness Phone3],
IIf([kindofloss]=1,"FIRE",IIf([kindofloss]=2,"THEFT",IIf([kindofloss]=3,"LIGHTNING",IIf([kindofloss]=4,"HAIL",IIf([kindofloss]=5,"FLOOD",IIf([kindofloss]=6,"WIND",IIf([kindofloss]=7,"OTHER","")))))))
AS [Calc-kindoflosstext],
IIf([Mortgagee]=1,"YES",IIf([Mortgagee]=2,"NO","")) AS
[Calc-MortgageeText],
IIf([subject1]=1,"BLDG",IIf([subject1]=2,"CNTS",IIf([subject1]=3,"BLKT","")))
AS [Calc-Sub1],
IIf([subject2]=1,"BLDG",IIf([subject2]=2,"CNTS",IIf([subject2]=3,"BLKT","")))
AS [Calc-Sub2],
IIf([subject3]=1,"BLDG",IIf([subject3]=2,"CNTS",IIf([subject3]=3,"BLKT","")))
AS [Calc-Sub3],
IIf([subject4]=1,"BLDG",IIf([subject4]=2,"CNTS",IIf([subject4]=3,"BLKT","")))
AS [Calc-Sub4],
IIf([subject5]=1,"BLDG",IIf([subject5]=2,"CNTS",IIf([subject5]=3,"BLKT","")))
AS [Calc-Sub5], dbo_Register.[CAT Number], dbo_AltLoss.VIN
FROM (dbo_AltLoss INNER JOIN dbo_Register ON dbo_AltLoss.[Claim Number]
= dbo_Register.[Claim Number]) INNER JOIN dbo_ZipCodes ON
dbo_AltLoss.[Producer Zip] = dbo_ZipCodes.ZIP
WHERE (((dbo_AltLoss.[Claim Number])=[Forms]![Atl Loss]![Claim
Number]));
Peter said:
Can you post the SQL code for the query here please?
Peter Jamieson