Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Help with SET KEY
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00791504
Message ID:
00791527
Views:
18
Pedro,

You must convert SET KEY TO ... to SET FILTER TO ...
LOCAL lii,lcTag,lcAFilter,lcNOrder,llSep
lcNOrder="New_Index"

lii=1
DO WHILE .T.
   lcTag=TAG(lii)
   IF EMPTY(lcTag)
      lcAFilter=""
      EXIT
   ELSE
      IF lcTag==lcNOrder
         * KEY()
         llSep=TYPE('SET("KEY",1)')="C"
         lcAFilter="BETWEEN("+KEY(lii)+","+;
                   IIF(llSep,"'","")+lcPom+IIF(llSep,"'","")+","+;
                   IIF(llSep,"'","")+SET("KEY",2)+IIF(llSep,"'","")+")"
         EXIT
      ENDIF
      lii=lii+1
   ENDIF
ENDDO
?lcAFilter
MartinJ

>Oh , it´s so bad !
>
>In my form i need change sometimes SET ORDER , I need use one SET KEY .
>
>I can´t use one SELECT SQL , because i open main table in dateEnvironment .
>
>Now , i don´t know , what i can do .
>
>Thanks
"Navision is evil that needs to be erazed... to the ground"

Jabber: gorila@dione.zcu.cz
Jabber? Jabbim
Previous
Reply
Map
View

Click here to load this message in the networking platform