Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
>Hi Everyone,
>
>
>
>SET SOAPBOX ON
>
>I'm sorry, but I must object to this technique of the USE of the underlying cursor. This creates a very interesting cursor that is updatable, but is "missing" some other stuff under the hood. It has been known to cause some issues that are very difficult to track down.
Chuck,
I tend to use this technique, so I'm interested in what is missing under the hood, and what difficult-to-track issues have been run into. I have not run into any problems yet, but don't want to continue in unsafe techniques!
>
>It is MUCH more straightforward (for both Fox and the poor developer who has to look at this code after you) to use INTO TABLE instead. This creates just what you want: a result set that is placed into something that can be updated. When you're done with it, just erase it. If you're worried about duplicate file names, use SYS(2015) for a unique one.
>
>SET SOAPBOX OFF.
>
>Thank you. I feel better, now. <g>
>-Chuck
>
>>SELECT ... INTO CURSOR MyCursor
>>
>>SELECT 0
>>USE DBF([MyCursor]) AGAIN ALIAS MyTemporaryTable
>>
>>REPLACE ...
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement