Grandtotal or grand total7/2/2023 ![]() ![]() INSERT INTO #mytable (Year, EmployeeID, Subtotal, GrandTotal, Void,įederalWages, FederalTax, FicaWages, FicaTax) = Insert the test data into the test table )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF,ĪLLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON Ĭurrently there are 2 fields (in bold above) that indicate if a record is a subtotal or grand total record. IF OBJECT_ID('TempDB.#mytable','U') IS NOT NULLĬONSTRAINT PRIMARY KEY CLUSTERED = If the test table already exists, drop it Here is a condensed version of the table I will be working with However, the user can update the records, but the subtotal/grand total records weren’t updated.Īs long as I can be pointed in a good direction, I will run with it and see what I can come up with. In the old program, the subtotal and grand total records were created when the data was initially generated. ![]() We are going to be rewriting this application and I would like to manipulate the data in a better way. This is something I am doing in a previous version through a report in an application. This also needs a final subtotal record before the grand total. I need to have to do a subtotal after XX records and a grand total at the end. I would like to know if there is a good way to have subtotal records and a grand total record within a result set.
0 Comments
Leave a Reply. |