Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Code for Cursor Readwrite
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01057981
Message ID:
01057993
Vues:
16
Hi Brenda,

I'm re-thinking. Is it multi-user environment? Do you allow several users to change this free table at the same time? What exactly do you want to achieve here?

Right now the last user overwrites changes that other users may have done. Is it your intent?

>Looking for ways to make my code more efficient or at least not as embarressing.
>
>1) have a VFP free table1.dbf. Want to select records from table1.dbf and then end up with a readwriteable cursor called table1.dbf. Currently I have the following sloppy lines of code.
>
>
>IF used("QM_cond")
>   USE IN qm_cond
>ENDIF
>USE qm_cond IN 0
>SELECT * FROM qm_cond into CURSOR temp READWRITE ;
>   WHERE f_query_id like qm_list.f_query_id+'%'
>USE IN qm_cond
>SELECT * FROM temp INTO CURSOR qm_cond readwrite
>USE IN temp
>SELECT qm_cond
>INDEX ON F_QUERY_ID TAG F_QUERY_ID
>SET ORDER TO TAG F_QUERY_ID
>
>
>
>2) do some processing, then want to then update table1.dbf with the records from cursor table1. currently I am co
>
>SELECT * FROM qm_cond INTO CURSOR temp
>USE IN qm_cond
>USE c:\rt50vss\data\qm_data\qm_cond IN 0
>DELETE FROM qm_cond WHERE f_query_id like qm_list.f_query_id+'%'
>SELECT qm_cond
>APPEND FROM DBF('temp')
>USE IN temp
>
>
>
>Any suggestions are appreciated
>
>Brenda
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform