Search results

  1. E

    0 or rejects not displaying

    Double click on the arrow and select the option to display all records from qryPlants. To display a numeric zero in the query results, you can change your expression to:- Expr1: Nz([The Value])+0 ^
  2. E

    Access Query help......

    For an answer to this part of your question, you can see Jon K's post in the recent thread: http://www.access-programmers.co.uk/forums/showthread.php?t=140983 ^
  3. E

    Filter by Combo box entry

    Try setting the criteria for the field in a new column in the query grid like the following (replacing with the correct field name):- ------------------------ Field: IIf([Combo32].[Value]="All", True, [FieldName]=[Combo32].[Value]) Show: uncheck Criteria: True ------------------------ See...
  4. E

    Calculating time difference from the record above

    Try this query. SELECT tblTag.ID, tblTag.Reg, (Select Max(Reg) from tblTag as S where S.ID=tblTag.ID and S.Reg<tblTag.Reg) AS PrevReg, Format(Reg-PrevReg,"hh:nn") AS TimeDiff FROM tblTag; ^
  5. E

    Query By Form

    If what you want is for the query to return field f1, f2 or f3 based on user-selection in the combo box, you have to have three separate queries. You can't change the fields to return at will in a query. Alternatively, you can use VBA code to build/edit the SQL statement of a query on the fly...
  6. E

    Time/Decimal convert

    Since a date/time field is internally a double precision number in days and there are 24 hours in a day, I believed the first expression should also work. It should even work without the need of the CDbl() function. To test what I believed, I put the following query in the attached database:-...
  7. E

    Crosstab IIf function - Need query between dates

    You can filter the records with a Where Clause. TRANSFORM .......... SELECT .......... FROM .......... WHERE Month([CONTACT_DATE]) In (10,11,12) GROUP BY .......... PIVOT ..........; ^
  8. E

    Help with InstrRev

    Try these for SEG1, SEG2 and Partname. IIF(InStr([DrawingDesc],"CNC"), Trim(Left([DrawingDesc],InStr([DrawingDesc],"CNC")-1)), Null) AS SEG1, IIF(Instr([DrawingDesc],"CNC"), Trim(Mid([DrawingDesc],InStr([DrawingDesc],"CNC")+3)), Null) AS SEG2, IIf(InStr([SEG2],"#"), Replace([SEG2],"#","")...
  9. E

    What type of query is this?

    I think you can do it only with VBA code, not queries. ^
  10. E

    Help needed with displaying Crosstab data in a Report

    You can force the crosstab query to display all the column heads by adding an In Clause after the Pivot Clause in query SQL View e.g. TRANSFORM .......... SELECT .......... FROM ........ GROUP BY .......... PIVOT ......... IN ("column headA","column headB", ...,"column headX"); ^
  11. E

    Entering Dates

    Try this query. SELECT tblWeeks.WeekNo, tblTMS.IDNo, tblTMS.Name, tblTMS.Address FROM tblTMS, tblWeeks WHERE tblTMS.DateReceived Between tblWeeks.StartDate And tblWeeks.EndDate And [Enter a date] Between tblWeeks.StartDate And tblWeeks.EndDate; ^
  12. E

    Create table AS Select Query

    SELECT * INTO [B_match] FROM [B_All] ^
  13. E

    REPLACE function

    Not sure if this helps ... but I recall reading somewhere that some versions of Access require the creation of a wrapper function in a Module for the replace function e.g. Public Function MyReplace(Fld, ReplThis, WithThis) As String MyReplace = Replace(Fld, ReplThis, WithThis) End Function...
  14. E

    Using <> Giving me Records it should not

    When two tables in a query are Not Joined by the = sign, each record in the first table is matched with each record in the second table. That is why when tblWorkPerformed contains more than one records it returns more records than you would expect as they all fulfil the condition...
  15. E

    Including End dates within forms

    I believe the poster's field does contain time too. That's why the query doesn't include the last date. Date/time field is internally a number so the + sign is needed. # is the delimiter for delimiting date/time value. On the other hand, ampersand (&) is for text concatenation. Using & instead...
  16. E

    How to Query a Table to find records showing checked boxes

    When you have used up all the OR rows in query Design View, you can switch the query to SQL View and add the Yes for the remaining fields in the Where Clause, though I have no idea how many OR criteria we can use in a query. I have never used that many in a query. ^
  17. E

    Including End dates within forms

    CDate() is a function and needs the brackets. Try this: Between [forms]![formname]![cbostartdate] And CDate([forms]![formname]![cboenddate])+#23:59:59# ^
  18. E

    Custom Order By?

    SELECT ............. FROM .......... WHERE ........... ORDER BY IIf([Status]="Entered", 0, IIf([Status]="Active", 1, 2)) ^
  19. E

    New Field Query

    Column 3: IIf([Column 2]=0, [Column 1], [Column 2]) ^
  20. E

    1 parameter controlled by multple combo boxes on a form

    Still not there. You may need to compact the database before zipping to make it smaller. ^
Back
Top Bottom