Zum Hauptinhalt gehen

Query Task Where clause using object variable

Kommentare

3 Kommentare

  • Richard Diaz
    Gary,  Try this:

     

    "LOT = '" + resultLotNum + "' AND CONCESSION = '" + resultConcession.ToString + "'"

     

    The object has to be converted to a string.  Make sure Intellisence is turned on in Workflow Designer.  When you type the word resultConcession and add a period, syntax will appear as shown below:

     

    _img_ alt="User-added image" src="https://latitudegeo--c.na53.content.force.com/servlet/rtaImage?eid=907f2000000XeH9&feoid=Body&refid=0EMf2000000YDUQ" _/_img_

     

    Rick
    0
  • Permanently deleted user
    Hi Rick,

     

    Thanks for the help with the expression and the Intellisence tip as well.

     

    Cheers,

     

    Gary
    0
  • Berend Veldkamp
    A small tip in addition to Richard's answer. I always recommend using the String.Format() method to keep things readable, e.g. String.Format("LOT = '{0}' AND CONCESSION = '{1}'", resultLotNum, resultConcession)

     

    Note that if resultLotNum or resultConcession could contain a single quote, you will have to escape them. 

     

     
    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.