Search results

  1. M

    Solved Multiple JOINs issue

    1. Thank you very much! Your fix did the job. 2. I was confused by this article which explicitly says that in multiple JOINs the following JOIN joins a table to the previous (intermediate) result set (not to the previous table)...
  2. M

    Solved Multiple JOINs issue

    1. How do I do it in the same FROM statement? 2. In my example I join CustomerCountry to the result set of the 1st JOIN (which has a record for Argentina) , not to SupplierCountry. Don't I?
  3. M

    Solved Multiple JOINs issue

    Northwind DB Customers and Suppliers tables both have Country column (there is no Country table in the DB, so the Country field is not a FK). Argentina has no suppliers, but 3 customers. "Produce a full list of countries (derived from Customers and Suppliers tables) with total number of...
  4. M

    Solved Cascading combo box - Sorting filtered results

    Can't find the correct syntax to make it work. Please help. Private Sub cboBrand_AfterUpdate() Me.cboProductID.RowSource = "SELECT ProductID, ProductName, ProductNumber FROM tblProduct WHERE BrandID = " & Me.cboBrand ORDER BY ProductName End Sub
  5. M

    Solved Date functions: subtraction

    I left 2020 by mistake, of course. It should have been MONTH(DATE())-1 gives 0. Thank you!
  6. M

    Solved Date functions: subtraction

    I am trying to build button-click dates' VBA filter and seem to miss some logic here. - How come the MONTH function in MONTH(DATE())-1 gives 0, but in DateSerial(YEAR(DATE()), MONTH(DATE())-1, DAY(DATE()) gives 12? - In case of DateSerial(YEAR(DATE()), MONTH(DATE())-1, DAY(DATE()) the result is...
  7. M

    Solved Filter continuous form on dates interval

    All I need is criteria, correct. I know how to apply a fixed criteria - in this form I have btnCurrentYear, btnLastMonth etc with predetermined filters, for example: Private Sub btnCurrentMonth_Click() DoCmd.ApplyFilter , "MONTH(OrderDate)=MONTH(Date())" End Sub But I could not figure out...
  8. M

    Solved Filter continuous form on dates interval

    Thanks again. A side question. Sub Search() Dim strCriteria, task As String strCriteria = "OrderDate between " & Format(Me.StartDate, "\#mm\/dd\/yyyy\#") & " and " & Format(Me.EndDate, "\#mm\/dd\/yyyy\#") task = "select * from qryListOfOrders where (" & strCriteria & ")"...
  9. M

    Solved Filter continuous form on dates interval

    only the midnight between 09/30 and 10/01, no?
  10. M

    Solved Filter continuous form on dates interval

    I guess I see. Edited to strCriteria = "Orderdate between " & Format(Me.StartDate, "\#mm\/dd\/yyyy\#") & " and " & Format(Me.EndDate + 1, "\#mm\/dd\/yyyy\#") Thank you!
  11. M

    Solved Filter continuous form on dates interval

    The Default Value of OrderDate is =Now() indeed. The unbound StartDate and EndDate text boxes do not have default values. I only enter date (select from the Date Picker)
  12. M

    Solved Filter continuous form on dates interval

    OrderDate field, Date/Time type, Medium Date format I recall now I've read something about time element playing games, but don't remember exactly.
  13. M

    Solved Filter continuous form on dates interval

    frmListOfOrders (based on qryListOfOrders) has unbound StartDate and EndDate text boxes and search button btnSearch . The search sub is: Sub Search() Dim strCriteria, task As String strCriteria = "OrderDate between " & Format(Me.StartDate, "\#mm\/dd\/yyyy\#") & " and " & Format(Me.EndDate...
  14. M

    Query run crashes Access

    I wonder what might be corrupted in 78 lines long simple table
  15. M

    Query run crashes Access

    BTW, just tried to add tblPurchaseDetails into the RunningTotals query itself ("super slamdank") - runs fine!
  16. M

    Query run crashes Access

    Created a new DB, exported only 3 tables queried in qrySalesCount (running total query). qrySalesCount runs fine, just like in the original DB. Created new Query1, added all the fields from qrySalesCount - runs fine. Merely added tblPurchaseDetails, no joining, no fields added to Query1 -...
  17. M

    Query run crashes Access

    Thank you very much for such a detailed reply. My DB is not split, so I don't have FE and BE. I tried both Compact & repair and migrating to a new DB - no effect. I was trying to run a query built from other query, which contains subquered Running Total of products sales linked to a table of...
  18. M

    Query run crashes Access

    As I said, it results in Cartesian multiplication (T2.OrderDetailsID times) of lines and does not give running total. My DB is quite small - less than 3000 lines of OrderDetailsID - so my original running total query runs fine and fast. It only crashes when used in another query - and I don't...
  19. M

    Query run crashes Access

    ACECORE.DLL is the culprit. The question is whether to try and update this DLL or to workout my query. Eventually I am looking for the simplest FIFO inventory solution that will track the count of sold products and replace the cost of purchase' value in order details accordingly, so I can...
Top Bottom