I have designed MS Access Table in which I have added Column name as "Closing Balance". I want to generate query so that it shows me opening balance and closing balance with respect of date as today's closing will be next day opening. the Formula of closing balance is "Total Amount Received - Total Amount Sent". The structure of the Table is as under.
I am using the following query but it does not show me any result. It shows me the blank query result. Here is the query.
SELECT (Select TOP 1 Closing_Balance From MainDB as Dup Where Dup.MainDB_Date <MainDB.MainD_Date);
Please anyone can help me thanks in advance.
Related
I have an SSRS report with two relevant Tablix, one is a weekly summary with all of the work orders associated with that project included and a total at the end. The other has weekly totals and then a running total for the project at the end. The report has a parameter to set the week end date, which allows the user to see all of the work orders included in the specified weeks.
Currently, when I run the report for a specific week end date, the first Tablix acts how I want it to, it shows all the work orders for that week and a total at the end. The second table, however, will just show the totals for the weeks included in the Week End Date parameter and a sum of those specific weeks.
I want the second Tablix to display the totals for each week and a sum at the end for all weeks up to the parameter specified week end date, not just the parameter specified ones. This is what I can't figure out. Currently it's set to the same value as the Week End Date, I've tried making an expression with an IIF statement but I haven't been able to get the right syntax for it, if that's even the right way to approach it.
Here is a snip of the Tablix, if it is helpful to include the expressions I can post those as well.
Thank you in advance for any guidance!
I have a query that would give me the opening stock for today, expected sales and purchases for the next few days (where there is no value for either, a null value is returned. What I would like to get to is to project the upcoming opening stock. How can I do this?
My current query would look very much like this in RedShift:
select date,opening_stock,sales,purchases
from inventoryandforecast
Current Output
I imagine that to accomplish the following output, I need to calculate a closing inventory for each day (where closing inventory = starting inventory - sales + purchases) and use either lag/lead for the opening inventory the next day, but I fail to understand how to do this. What should my query look like?
Intended output
Thank you for your time.
I'm running a report off of a query to create room signs showing people in that room. The query shows the actual room number, but when I create the report from the query, the ID number for the room is shown instead. How do I fix this?
My apologies, I am a bit of a novice in access and I can't seem to find the solution for the below:
I have a simple access database for monitoring the number of hours spent on a task. At the point that this activity exceeds 7 hours I would like for the record to be updated to signify this fact, possibly with a time stamp indicating the month and year in which this was exceeded.
The information regarding hours spent on the task would be manually entered on a single given day of the month, and the 7+ hours can be collected over a number of months. It is however necessary to be able to produce reports from the data with breakdowns indicating how many tasks exceeded the 7 hours, and on which month did this happen.
How do I set that automated rule/action to update the record on the 7 hours threshold? (Each record currently contains a single field with a running total of hours recorded)
There are a number of ways that you can do this if you are using a Form to insert new records into your table. It would also help if you have some knowledge of VBA
If you are are using MS Access 2013, you could also use Data Macros (MS Access equivalence of SQL Server triggers).
Assuming that you are using a lower version of Access and assuming that you are using a Form to insert/update Data into your table, the following could be done:
1. Create a query that summarize all hours spent group by taskID (*SELECT TaskID, SUM(Task_Hours) AS TotalHours FROM Tasks GROUP BY TaskID* let call this Query TasksTotals)
2. Modify your Tasks table to Include Date/Time you can call it TaskDate) and another field called SeventhHourReached with a Boolean or a text value to be Yes or No
3. Create another Query that filters all tasks that have already reached the 7th hours (SELECT TaskID FROM Tasks Where SevethHourdReached ="Yes" GROUP by TaskID) - Lets call this query Tasks7H
Now you will need to do some VAB
Of your Form's Current Event procedure or on your form field hours After Update
use the following event procedure in VBA
If DLookup("TotalHours", "TasksTotals", "TaskID = " & Me.TaskID &"") >= 7 Then
If DLookup("TaskID", "Tasks7h", "TaskID = " Me.TaskID & "") <> Me.TaskID Then
Me.SevethHoursReached = "Yes" ----- This is you used a text field
End If
End if
Make sure the field SevethHourReached shows on your Form but disabled or locked or disabled and locked.
For you reports, you will have the date and time when the seveth hour was reached if you just used the function now() for the default value on your TaskDate field. You can filter all the records which have the sevethhourreached as yes for your report query.
I want to make an excel graphic with 3 values:
Sales Order Date (The date sales enters the sales order)
Requirement Date (The date the customer wants this order)
Closed Sales Order Date (When sales closes the order)
This will be used to measure the service of our plant against completed delivered sales orders monthly.
I already found the first 2 data cells on table VBMTV, anyone has an idea where can I get the information regarding as the date sales close the order once it has been delivered to the customer?
Regards,
Assuming that the data is displayed in a transaction, you can do the following:
position the cursor in the field you are interested in
press F1 - you get a help text in a dialog labeled 'Performance Assistant'
click the button for 'Technical Information' (looks like a hammer and wrench) - you'll get another dialog
in this dialog there are fields for 'Table Name' and 'Field Name'
For most transactions, this information maps to the specific tables/columns in the database. There are some exceptions to this rule (mostly for those cases where the data is not directly read from the db), but it is a good start and works for about 80% of the cases.
If F1 and Technical Information (F4) does not work you can also try running a trace using ST05. (Do this only for one user and make sure to disable the trace once you are done).
I believe Sales Order Complete may be a status. (TECO or "Technically Complete" if I'm correct). The table that stores the date a specific status was set is JCDS. You will have to read it on the OBJNR of the sales order and the internal status number of the status that you care about.