Search results

  1. 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...
  2. 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
  3. 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...
  4. 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...
  5. M

    Query run crashes Access

    qrySalesCount counts products sales (the FO part of FIFO): SELECT T1.ProductID, tblProduct.ProductName, T1.OrderID, tblOrder.OrderDate, T1.Quantity, T1.UnitCost, (SELECT Sum(tblOrderDetails.Quantity) AS Total FROM tblOrderDetails WHERE tblOrderDetails.OrderDetailsID <=...
  6. M

    Run-time error '3075': Syntax error (missing operator) in Access 2013 but not in 2010

    Hello dear experts. In my frmListOfOrders I have unbound StartDate and EndDate text boxes as well as search buttons for several predefined intervals (btnCurrentMonth, btnLastMonth etc.). The underlying code for the search sub is: Sub Search() Dim strCriteria, task As String Me.Refresh If...
  7. M

    Open List Items Edit form on new record

    In frmOrders, when adding notinlist value in combobox "CustomerID" a List Items Edit data property triggers frmCustomers form to open. It opens on the 1st existing record (CustomerID=1). I need it to open on new record (preferably inheriting the entered new customer's name, but this is less...
  8. M

    Solved Lock form based on combobox

    I am building a simple Order form with OrderDetails subform. I need all the controls on the main form (CustomerName, OrderDate etc) and on the subform (Quantity, Listprice etc) to become locked (changes disabled) once I select Closed status in the OrderStatus combobox of the main Order form...
Top Bottom