How to cap old reputation ratings with a query?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Alfa1
    Senior Member
    • Dec 2005
    • 4165
    • 3.8.x

    How to cap old reputation ratings with a query?

    The reputation system has a central role at my site. We have been using it from 2005 and it has done wonders for my site.

    Along time members got a higher and higher reputation power and kept giving out max reputation points. Until the ratings became so ridiculously high that it was impossible to base promotions and other important factors on it. So we needed to cap the number of reputation points that could be given by setting out guidelines. That works well.

    But to level current ratings with old ratings, I want to edit all old ratings higher than 30 points and make them 30 point ratings.

    Can this be done with a query?
    I buy 420 forums
  • Trevor Hannant
    vBulletin Support
    • Aug 2002
    • 24325
    • 5.7.X

    #2
    Yes, you should be able to do this with a query in phpMyAdmin. Make sure you backup your database first before doing this.

    You could try something along the lines of:

    Code:
    [FONT=Verdana]
    [/FONT]UPDATE  `user`  SET  `reputation`  =30 WHERE  `reputation`  >30
    Vote for:

    - Admin Settable Paid Subscription Reminder Timeframe (vB6)
    - Add Admin ability to auto-subscribe users to specific channel(s) (vB6)

    Comment

    • Alfa1
      Senior Member
      • Dec 2005
      • 4165
      • 3.8.x

      #3
      I assume that the table prefix needs to be added to the user table. i.e.
      UPDATE `prefix_user` SET `reputation` =30 WHERE `reputation` >30

      Am I correct that this will not affect negative reputation ratings lower than -30 ?
      I buy 420 forums

      Comment

      • Trevor Hannant
        vBulletin Support
        • Aug 2002
        • 24325
        • 5.7.X

        #4
        Yes, you will need to add the prefix.

        The WHERE condition looks for records that are over 30 (i.e. 31 and above) so it should affect others. As I said though, take a backup before running this.
        Vote for:

        - Admin Settable Paid Subscription Reminder Timeframe (vB6)
        - Add Admin ability to auto-subscribe users to specific channel(s) (vB6)

        Comment

        widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
        Working...