Help in SQL query

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

    Help in SQL query

    I need to select records that begin with the letter A or B or C.. etc

    Here is my select query:

    SELECT '<a href="' & LINK & '"> ' & PLANNAME & '</a>' AS hyperl
    FROM TABLE;


    Where in here would I add A* to only pull PLANNAME records that start with A?
  • Robin Tucker

    #2
    Re: Help in SQL query

    SELECT '<a href="' & LINK & '"> ' & PLANNAME & '</a>' AS hyperl
    FROM TABLE
    WHERE TABLE.PLANNAME LIKE 'A%'

    I think ;)


    "Brian Jorgenson" <bjorgenson@cha rter.net> wrote in message
    news:34ec3ea7.0 404200857.1c331 183@posting.goo gle.com...[color=blue]
    > I need to select records that begin with the letter A or B or C.. etc
    >
    > Here is my select query:
    >[color=green]
    > >[/color]
    >
    > Where in here would I add A* to only pull PLANNAME records that start with[/color]
    A?


    Comment

    • Brian Jorgenson

      #3
      Re: Help in SQL query

      Yes, you are right. This is what I have and it works great:

      SELECT '<a href="' & LINK & '"> ' & PLANNAME & '</a>' AS hyperlink, PlanName AS Plan
      FROM PLANNAME
      WHERE ((([PlanName]) Like "*"));



      "Robin Tucker" <idontwanttobes pammedanymore@r eallyidont.com> wrote in message news:<c63lq5$mq 7$1$8302bc10@ne ws.demon.co.uk> ...[color=blue]
      > SELECT '<a href="' & LINK & '"> ' & PLANNAME & '</a>' AS hyperl
      > FROM TABLE
      > WHERE TABLE.PLANNAME LIKE 'A%'
      >
      > I think ;)
      >
      >
      > "Brian Jorgenson" <bjorgenson@cha rter.net> wrote in message
      > news:34ec3ea7.0 404200857.1c331 183@posting.goo gle.com...[color=green]
      > > I need to select records that begin with the letter A or B or C.. etc
      > >
      > > Here is my select query:
      > >[color=darkred]
      > > >[/color]
      > >
      > > Where in here would I add A* to only pull PLANNAME records that start with[/color]
      > A?[/color]

      Comment

      Working...