Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2004
    Posts
    56

    Unanswered: Assistance with a formula please.

    I am trying to make a formula work and obviously have it wrong. Essentially if the field VNDAD1 equals an entered value, such as RETAIL ADVERTISING then another field VENDOR_CLASS will then equal E otherwise anything else gets an S. This formula I built on my limited (but learning) knowledge of Access in the expression builder.

    Could someone please tell me what I did wrong?

    IIf([Combined_PS]![VNDAD1]="RETAIL ADVERTISING" Or ([Combined_PS].[VNDAD1])="NEWS ROOM",[Combined_PS]![VENDOR_CLASS]="E",[Combined_PS]![VENDOR_CLASS]="S")


    thanks ahead of time

  2. #2
    Join Date
    Mar 2004
    Location
    www.scirocco.ca
    Posts
    346

    Re: Assistance with a formula please.

    Your formula looks good. What error are you getting?
    http://www.scirocco.ca/images/banner...occobanner.gif

    Download for FREE the ADO/DAO Data Controls that makes life EASIER developing database applications in: VB, FoxPro, Access, VC++, .NET etc... Navigate, Add New, Delete, Update, Search, Undo and Save your changes. Supports Disconnected Recordsets and Transactions!

    Or try our Ask An Expert service to answer any of your questions!

  3. #3
    Join Date
    Mar 2004
    Posts
    56
    Not really getting an error, let me explain.

    in my query I have my table Combined_PS then the two field selections

    Field: VNDAD1
    Table: Combined_PS
    Sort: blank
    show: Checked
    Criteria: the above formula

    -------------------------------------

    Field: VENDOR_CLASS
    Table: Combined_PS
    Sort: blank
    show: Checked
    Criteria: blank

    now I know I have rows/records with RETAIL ADVERTISING in it, so when I run the query it comes up with 0 recordes and so the vendor class field stays at its default S

Posting Permissions

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