criteria that with a value containing an asterisk

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Coll

    criteria that with a value containing an asterisk

    I'm working with a form & a query that allows the user to filter the
    data using several combo boxes. One of the combo boxes allows them to
    select the first letter of a a particular field, and it will use that
    first letter in the criteria of the query to include only records with
    a value beginning with that letter. The tricky part is that one of the
    possible values for that field is - *.* - not values I would have
    chosen, but they are coming from another system, so I have no control
    over it. If you select the * value, it ends up returning all of the
    records. Is there any way I can still use this setup, and still filter
    for records beginning with an asterisk? I tried enclosing the asterisk
    in quotes, but it doesn't return any values. i'm stumped - any
    suggestions?
  • fredg

    #2
    Re: criteria that with a value containing an asterisk

    On Mon, 4 Aug 2008 05:02:50 -0700 (PDT), Coll wrote:
    I'm working with a form & a query that allows the user to filter the
    data using several combo boxes. One of the combo boxes allows them to
    select the first letter of a a particular field, and it will use that
    first letter in the criteria of the query to include only records with
    a value beginning with that letter. The tricky part is that one of the
    possible values for that field is - *.* - not values I would have
    chosen, but they are coming from another system, so I have no control
    over it. If you select the * value, it ends up returning all of the
    records. Is there any way I can still use this setup, and still filter
    for records beginning with an asterisk? I tried enclosing the asterisk
    in quotes, but it doesn't return any values. i'm stumped - any
    suggestions?
    For just a leading asterisk, place the * within brackets.

    Like "[*]" & "*"

    For the *,* combination, use:
    Like "[*]" & "," & "[*]" & "*"
    --
    Fred
    Please respond only to this newsgroup.
    I do not reply to personal e-mail

    Comment

    • Coll

      #3
      Re: criteria that with a value containing an asterisk

      On Aug 4, 10:46 am, fredg <fgutk...@examp le.invalidwrote :
      On Mon, 4 Aug 2008 05:02:50 -0700 (PDT), Coll wrote:
      I'm working with a form & a query that allows the user to filter the
      data using several combo boxes. One of the combo boxes allows them to
      select the first letter of a a particular field, and it will use that
      first letter in the criteria of the query to include only records with
      a value beginning with that letter. The tricky part is that one of the
      possible values for that field is - *.* - not values I would have
      chosen, but they are coming from another system, so I have no control
      over it. If you select the * value, it ends up returning all of the
      records. Is there any way I can still use this setup, and still filter
      for records beginning with an asterisk? I tried enclosing the asterisk
      in quotes, but it doesn't return any values. i'm stumped - any
      suggestions?
      >
      For just a leading asterisk, place the * within brackets.
      >
      Like "[*]" & "*"
      >
      For the *,* combination, use:
      Like "[*]" & "," & "[*]" & "*"
      --
      Fred
      Please respond only to this newsgroup.
      I do not reply to personal e-mail
      Works great - thank so much!!

      Comment

      Working...