IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 30644


Ignore:
Timestamp:
Feb 15, 2011, 4:35:49 PM (15 years ago)
Author:
watersc1
Message:

Rank by deviation from average value. This eliminates the extra ranking involved with R. I'm not sure that the R ranking was really helping us that much.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Nebulous-Server/bin/neb-admin

    r29669 r30644  
    312312      SELECT mountedvol.vol_id,mountedvol.name,mountedvol.available,mountedvol.allocate,total,used,
    313313             (used / total) AS D,total * ((used / total) - $average ) AS R,  -- average
     314             (used / total) - $average AS delta,
    314315             cab_id FROM
    315316      mountedvol JOIN volume USING(vol_id)
    316317      WHERE mountedvol.available = 1
    317       ORDER BY R DESC LIMIT $balance_N_sources                                            -- N
     318      ORDER BY delta DESC LIMIT $balance_N_sources                                            -- N
    318319      ) AS ranked_sources
    319320      -- Z End
     
    337338   SELECT mountedvol.vol_id,mountedvol.name,mountedvol.host,mountedvol.available,mountedvol.allocate,total,used,
    338339          (used / total) AS D,total * ((used / total) - $average ) AS R,  -- average
     340          (used / total) - $average AS delta,
    339341          cab_id FROM
    340342   mountedvol JOIN volume USING(vol_id)
    341343   WHERE mountedvol.available = 1 AND mountedvol.allocate = 1
    342    ORDER BY R ASC LIMIT $balance_M_destinations                                               -- M
     344   ORDER BY delta ASC LIMIT $balance_M_destinations                                               -- M
    343345  ) AS ranked_destinations
    344346  -- Z2 End
Note: See TracChangeset for help on using the changeset viewer.