Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2006
    Posts
    82

    Unanswered: very quick stored proc syntax question

    hi all

    i am doing a select statement with a where clause that has a like '%000000334'

    what i am trying to acomplish is to write the where clause with a variable

    where trancmt like '%@iInvcNo%'

    what would be the correct way to write this?

    thanks
    tibor

  2. #2
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,800
    Provided Answers: 11
    This usually works:
    Code:
    where trancmt like '%' + @iInvcNo + '%'

  3. #3
    Join Date
    Mar 2006
    Posts
    82
    ah thanks a million!

Posting Permissions

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