1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Need query to show all IPs by user

Discussion in 'XenForo Questions and Support' started by Blue, Jun 26, 2011.

  1. Blue

    Blue Well-Known Member

    Could someone post a query that would show all IPs used by a user?
     
  2. Slavik

    Slavik XenForo Moderator Staff Member

    SELECT * FROM `xf_ip` WHERE `user_id` =1337

    Change 1337 to the users id number
     
  3. Blue

    Blue Well-Known Member

    Thank you.
     
  4. tonjohn

    tonjohn Member

    Does Xenforo have an index on IPs by default? I know vb didn't and we had to add one or else our moderators will kill the forums hunting down ban evaders.
     
  5. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Yes I see an index for IPs in the schema. XenForo also stores IPs as integers which has performance benefits, especially when you are searching for a range of IPs.
     
    tonjohn likes this.
  6. tonjohn

    tonjohn Member

    Thanks for the info! I just bought a license to play around with and haven't had a chance to look at it yet.
     

Share This Page