Page 2 of 2 FirstFirst 12
Results 16 to 18 of 18
  1. #16
    CJ_London is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,446

    it may look the same, but the function is returning a string, not a date

    with regards attachments this is what I see
    Click image for larger version. 

Name:	image_2023-09-15_155326213.png 
Views:	13 
Size:	6.3 KB 
ID:	50768

    perhaps you didn't click the upload file

    It accepted it (in a table entry) without a problem.
    No problem because it ignores it and leaves it as null

    for your criteria, try

    cDate(fDt(....)

  2. #17
    twgonder is offline Expert
    Windows 10 Access 2021
    Join Date
    Jun 2022
    Location
    Colombia
    Posts
    658
    I don't know if this is going to always work, but somehow Eval() takes the string from the Dt (), and Query Builder accepts it.

    Click image for larger version. 

Name:	230915Dates4.jpg 
Views:	10 
Size:	56.4 KB 
ID:	50769
    I'm using Mike's code for Dt() here

    Click image for larger version. 

Name:	230915Dates5.jpg 
Views:	10 
Size:	45.2 KB 
ID:	50770

    I've been switching between USA and Latin regions for testing, so the dates may appear incongruent.

    I don't know how Mike's function served him for 10 years for Nulls. It won't work with Eval(), and I doubt it will work in a string build for VBA to pass to SQL.
    I'll do more testing.

    After note: I had to go back and reread the blog by Mike, he does mention using the null for UPDATE and INSERT queries, and that it won't work in WHERE.
    Quoth thy SQL? Evermore! (nolongerset.com)

  3. #18
    twgonder is offline Expert
    Windows 10 Access 2021
    Join Date
    Jun 2022
    Location
    Colombia
    Posts
    658
    Quote Originally Posted by CJ_London View Post
    with regards attachments this is what I see
    Click image for larger version. 

Name:	image_2023-09-15_155326213.png 
Views:	13 
Size:	6.3 KB 
ID:	50768

    perhaps you didn't click the upload file
    I have no idea, I didn't paste it and it shows in my uploads.
    I may have switched to advanced mode while writing the post, and maybe that messed things up?
    In any case, the links still work fine for me. Strange.

Page 2 of 2 FirstFirst 12
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Why is it so hard to explain VBA?
    By DigitalAdrenaline in forum Access
    Replies: 1
    Last Post: 08-20-2016, 06:04 AM
  2. Hard to explain how to do this?
    By flemingjo in forum Forms
    Replies: 1
    Last Post: 08-29-2014, 06:03 AM
  3. Can someone explain what this means?
    By Jay13 in forum Access
    Replies: 5
    Last Post: 05-23-2013, 04:22 PM
  4. Explain iif in ms access
    By pabbiraj in forum Programming
    Replies: 2
    Last Post: 05-27-2012, 01:20 AM
  5. Could someone please explain to me what a Switchboard is
    By wabbalee in forum Database Design
    Replies: 2
    Last Post: 06-26-2009, 07:20 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums