Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Microsoft's response on VFP Advanced
Message
De
18/12/2018 13:31:26
John Ryan
Captain-Cooker Appreciation Society
Taumata Whakatangi ..., Nouvelle Zélande
 
 
À
18/12/2018 09:41:27
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrats & ententes
Divers
Thread ID:
01664566
Message ID:
01664607
Vues:
109
>>parentid = curnewtrans->newtrans

Thanks for the -> , a reminder of good old days I'd not seen since well before the mdot wars. ;-)

As Kevin notes, I'm referring to the Sequence feature added in SQL Server 12. It's a very efficient way to get a unique value before you commit, and an easy way to convert a dbc's Autoinc SP or function if one of those is still in use. It's quicker and more efficient than GUID and includes the ability to "cache" sets of (say) 10 values that get doled out without updating the underlying resource until another batch is needed.

It also turns out that the default field type for Sequence is bigint and you can overcome this issue by defining the Sequence as INT. So much for a bug!

As an aside: if your commandstring is parameterized, I think SQL Server automatically caches the plan whether you SQLPrepare() or not. Or so I'm told.
"... They ne'er cared for us
yet: suffer us to famish, and their store-houses
crammed with grain; make edicts for usury, to
support usurers; repeal daily any wholesome act
established against the rich, and provide more
piercing statutes daily, to chain up and restrain
the poor. If the wars eat us not up, they will; and
there's all the love they bear us.
"
-- Shakespeare: Coriolanus, Act 1, scene 1
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform