6 Replies Latest reply: Jul 29, 2014 8:49 AM by Friedrich Hofmann RSS

    High-cardinality keyfield - any way to improve?

    Friedrich Hofmann

      Hi,

       

      I am still reworking an old piece of code. In short, it does this:

      - There is a target_value for every day, for each of the two shifts, for each of the areas
         -> there are about 30-40 values every day

      - That table is joined, via the date, to one Autogenerate_table with minute_intervals from 5:20 am to 10:30 pm

       

      -> Then - here comes the big one - a keyfield is loaded that is made up of the date and any of these minute_intervals - so there are

          a bit over 1.000 keyfields for one day. That blows up the table to millions and millions of records of course.

       

      => Is there any way of doing this more efficiently (without touching the key first, it is assumedly required on a minute_basis)?

       

      Thanks a lot!

       

      Best regards,

       

      DataNibbler