Results 1 to 2 of 2
  1. #1
    menonoting is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Sep 2011
    Posts
    1

    IF in Excel VS IIF in Access

    Hello All:
    I'm totally new in Access but I'm good with Excel this formula works for me in excel can someone tell me why it does not work in Access?
    Code:
    =IF(OR([First]="",[Last Name]=""),"Name Missing",
    IF(AND([Middle Name]="",[Suffix]>0),[First]&" "&[Last Name]&" "&[Suffix]&"." ))
    I know IF must be IIF

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    The syntax in Access is slightly different for the "and" and "or' portion of an IIF statement. Look at this site and scroll down to the last example to see how it works.

    http://www.techonthenet.com/access/f...vanced/iif.php

    Alan

Please reply to this thread with any new information or opinions.

Similar Threads

  1. excel link with access differs from simple export from access
    By M0RDANT in forum Import/Export Data
    Replies: 4
    Last Post: 03-25-2013, 02:43 PM
  2. import excel file to access 2003 yes, access 2007 no
    By stapik in forum Import/Export Data
    Replies: 9
    Last Post: 07-27-2011, 07:09 AM
  3. From Excel VBA to Access VBA
    By theracer06 in forum Programming
    Replies: 3
    Last Post: 09-08-2010, 08:41 AM
  4. looking for help access/excel
    By cusefan75 in forum Access
    Replies: 1
    Last Post: 07-22-2010, 09:06 AM
  5. Replies: 1
    Last Post: 08-31-2009, 10:24 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