swap data between 3 fields?

  • The 96 columns you're talking about each identify a region id for a person... and, I imagine that you have some nulls on each row. To normalize the table, each region/person combination would be found on a single row. Instead of a very wide table, you'd end up with a long skinny table which could be both easily and effectively indexed for performance and would make for some very simple queries.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • I was wondering about something like that, but wasn't sure how to. but as I said earlier I've gone with the other way and it seems to be working ok. I'm always keen to learn though... Thanks again Jeff and others that have helped me with this project, no doubt I'll probably call on you again in the near future

Viewing 2 posts - 16 through 16 (of 16 total)

You must be logged in to reply to this topic. Login to reply