>SELECT .... && your "I want to use here vfp Statement" >lcList = [] >SCAN > lcList = lcList + IIF(EMPTY(lcList),[],[,]) + TRANSFORM(FieldName) >ENDSCAN > >SQLExec(gnconnhandle,'select * from product where prcode in ('+ lcList+ ')','product') > >Please beware that you are creating a possible SQL injection attack. All that has to happen is for the line lcList = [] to be changed to lcList = something user entered.
lcList = [] SCAN lcList = m.lcList + TRANSFORM(FieldName) + "," ENDSCAN lcList = LEFT(m.lcList,len(m.lcList)-1)http://msvfp.advisorguide.com/doc/14710