Good Afternoon!
I am having a problem with DSum on a form.
I am using a sub-form and would like the last column to be a running total.
My 'appropbal' column (field from query) works just fine but if there are 2 entries I would like it to be a running total in a different column.
So far I have: =DSum("[AppropBal]","AppropBalanceQuery")
The criteria is in the query for the 'appropbal' and I am using an unbound text box on the form for the control.
Below is the SQL from the query that made the sub-form:
SELECT Expenditures.ExpenditureID, ProjectInformation.[Campus Name], ProjectInformation.[Project Number], Expenditures.Date, FundingSource.[Funding Source], [FundingSource.Funding Source] & " - " & [TypeProject.TypeProject] AS Source, TypeProject.TypeProject, ProjectInformation.ProjectAppropriation AS [Initial Approp], ProjectInformation.SShareBudget AS [Initial Project Budget], [Additions]+[Interchanges] AS Changes, [ProjectAppropriation]+[Changes] AS [New Approp], [SShareBudget]+[Changes] AS [New Project Budget], Expenditures.Additions, Expenditures.Interchanges, Expenditures.Expenditures, [New Approp]-[New Project Budget] AS AppropBal, [New Project Budget]-[Expenditures] AS ProjectBal
FROM TypeProject INNER JOIN ((FundingSource INNER JOIN Expenditures ON FundingSource.FundingSourceID = Expenditures.FundingSource) INNER JOIN ProjectInformation ON (Expenditures.ProjectNumber = ProjectInformation.[Project Number]) AND (FundingSource.FundingSourceID = ProjectInformation.FundingSource)) ON (TypeProject.ProjectTypeID = ProjectInformation.[Type Project]) AND (TypeProject.ProjectTypeID = Expenditures.TypeProject)
ORDER BY Expenditures.ExpenditureID, [FundingSource.Funding Source] & " - " & [TypeProject.TypeProject];
All the fields except the one I am trying to create w/ DSum are accurate from the query.
Can you help me?
Thank you.
Sue
I am having a problem with DSum on a form.
I am using a sub-form and would like the last column to be a running total.
My 'appropbal' column (field from query) works just fine but if there are 2 entries I would like it to be a running total in a different column.
So far I have: =DSum("[AppropBal]","AppropBalanceQuery")
The criteria is in the query for the 'appropbal' and I am using an unbound text box on the form for the control.
Below is the SQL from the query that made the sub-form:
SELECT Expenditures.ExpenditureID, ProjectInformation.[Campus Name], ProjectInformation.[Project Number], Expenditures.Date, FundingSource.[Funding Source], [FundingSource.Funding Source] & " - " & [TypeProject.TypeProject] AS Source, TypeProject.TypeProject, ProjectInformation.ProjectAppropriation AS [Initial Approp], ProjectInformation.SShareBudget AS [Initial Project Budget], [Additions]+[Interchanges] AS Changes, [ProjectAppropriation]+[Changes] AS [New Approp], [SShareBudget]+[Changes] AS [New Project Budget], Expenditures.Additions, Expenditures.Interchanges, Expenditures.Expenditures, [New Approp]-[New Project Budget] AS AppropBal, [New Project Budget]-[Expenditures] AS ProjectBal
FROM TypeProject INNER JOIN ((FundingSource INNER JOIN Expenditures ON FundingSource.FundingSourceID = Expenditures.FundingSource) INNER JOIN ProjectInformation ON (Expenditures.ProjectNumber = ProjectInformation.[Project Number]) AND (FundingSource.FundingSourceID = ProjectInformation.FundingSource)) ON (TypeProject.ProjectTypeID = ProjectInformation.[Type Project]) AND (TypeProject.ProjectTypeID = Expenditures.TypeProject)
ORDER BY Expenditures.ExpenditureID, [FundingSource.Funding Source] & " - " & [TypeProject.TypeProject];
All the fields except the one I am trying to create w/ DSum are accurate from the query.
Can you help me?
Thank you.
Sue