• Thanks to all for the comments, and for isolating the points needing clarification.

    Certainly, this is not the only way to do things, and it is only a suggestion, wich probably only suits a very limited set of circumstances. So let me clarify the circumstances:

    * This was part of an ETL process, where it was the only process in a sequence using the server - so no other active users. I certainly would not use it in a multi-user scenario. Locking & blocking would be inevitable.

    * The box had many processors & large amounts of memory - and as is recommended practice, one tempdb file per core on a fast array

    Sorry to have to be vague about exact 'specs, my client is nervy about any disclosure, and I have to get articles vetted...(!)

    And some more context - the destination tables contain 100 million-odd records at this stage in the process.

    So, isolating the ID sequencing to the source data (and avoiding joins to destination tables), as well as use of temp tables was more hard work to set up - but faster in this (possibly rare) context.

    What I will do if & when I get the time is try some comparisons between the two approaches, and see if varying the context (source file no of records, No of records in destination tables etc) provides any thing decent to comment on. However I cannot promise this for anytime soon, I am afraid.

    Thanks again for taking the time to comment - and I am sorry that this context was not made clearer in the article.

    Adam