Search results

  1. M

    Dsum issue

    I would like to know if this is possible? my report date is in 1 table and my data is in a seperate table. I would like to sum my hours from the Appleton table from a date range in the YearMonth table Public Function CorpRIR() Dim mySum Dim begD As Variant Dim endD As Variant Dim number...
  2. M

    Sum last 12 rows for calculation

    Pat, Sorry for being so thick I am taking it you mean that fld1 = cases, fld 2=hours and the where clause goes in the report date. If I do this and run the query even without the formula, I get a empty result. attached example
  3. M

    Sum last 12 rows for calculation

    also, please remember the reason that I want to sum the last 12 months is so that I can use this number in another formula. Formula is: 12 month total for [cases] *200000/12month total [hours] Thanks
  4. M

    Sum last 12 rows for calculation

    Thank you. You are correct and I do still think in terms of rows and columns. I am still confused on summing the months. I can see that I can sum each month individually, but I need a sum of the hours for the last 12 months. I did go through a video training program on Access, but I do not...
  5. M

    Sum last 12 rows for calculation

    Thanks for the reply, your right I must not understand Access and I am just surprised that it is so very dificult to do simple calculations. The reason I wanted to sum the last 12 data points was because this is a 12 month rolling average. I apoligize as I did not attacth the date table. The...
  6. M

    Sum last 12 rows for calculation

    Pat, I know that I am new to this, but I believe that what I want to do is not impossible. I do agree with you that the sort order of my database is important. This database will be hidden and always sorted by ID. The reason I needed to sum the numbers was so that I could calculate my RIR. I...
  7. M

    Sum last 12 rows for calculation

    I solved this Here is the funciton I wrote and then put it in a query. Function sumHoursAppleton(INDx) As String Dim db As Database Dim Lrs As DAO.Recordset Dim LSQL As String Dim LGST As String 'Dim INDx As Integer Dim Sum As Double Dim mySum As Double Dim myTotal As Integer 'Open connection to...
  8. M

    Sum last 12 rows for calculation

    Good Afternoon, I am a new to Access. I was hoping someone would be kind enough to help me with an issue I am facing. I have a table with 4 columns: ID (1,2,3,4,...),Cases, Hours, RIR. In the RIR column I would like to use the following formula. I would like to use a query to Sum the last 12...
  9. M

    Sum last 12 rows for calculation

    Here is a sample database with some made up numbers, but it represents what I would like to do. In the RIR column, I would like the calculation that I stated in an early post. I was thinking that I would probably have to wrap it in a if/then statement as the 1st 11 recordes would not have enough...
  10. M

    Sum last 12 rows for calculation

    Thanks for the reply. I do have a Primary key column that is numbered. It starts at 1. The ID column is also a foreign key to the Year/Month table which is auto numbered. It is in a 1 to 1 relationship. Could I use this column to order my data. Note: the Year/Month table is the Master table...
  11. M

    Sum last 12 rows for calculation

    Good Afternoon, I am a new to Access, but have programmed in Excel. I was hoping someone would be kind enough to help me with an issue I am facing. I have a table with 3 columns: Cases, Hours, RIR. In the RIR column I would like to use the following formula. Sum the last 12 rows in the cases...
Top Bottom