Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2015
    Posts
    1

    Unanswered: Can I convert a SQL Case When Statement in MS Access

    I am trying to convert a SQL Statement in MS Access 2010 (see below):

    Case When to_char(i.issue_start_dt,'MM/DD/YYYY') is null
    then ' '
    else 'FY'||To_Char(add_months( i.issue_start_dt,3),'YYYY') || ' QTR-0'||To_Char(add_months(i.issue_start_dt,3),'q')
    End "Start FY QTR"

    Is this possible in MS Access 2010?

    Thanks!

    Cricket

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    I don't think Access supports CASE statements, so consider using iif instead
    eg:
    Code:
    iif(isnull(i.issue_start_dt,NULL,dateadd("M",3, i.issue_start_d)) as Start_FYR
    whilst you are at it, use the appropriate datetime functions within Access JET
    I'd rather be riding on the Tiger 800 or the Norton

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •