Home Forums SQL Server 2008 T-SQL (SS2K8) Is there a better faster way then REPLACE in this example? RE: Is there a better faster way then REPLACE in this example?

  • ghughes (9/23/2016)


    Sergiy you are right again! The data changes, but not so much that I cant run a process every night/week and create a table of distinct full descriptions, and then create a stripped down version from the function. Then when I run my normal process it will be a table join instead of the scalar function on every row. Indexed properly it will contribute a lot on the speed.

    I used a sample is 100,000 of raw data. My production is a little bit more that. If I can squeeze my job in the schedule, it should help on processing during the day also. A win.

    Thanks again. This one has been actually a lot of fun. 🙂

    You're very welcome.

    🙂

    Remember - data normalisation is your best friend in the world of relational databases.

    😎

    _____________
    Code for TallyGenerator