Announcement

Collapse
No announcement yet.

Who has the most vistor messages on their profile?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Who has the most vistor messages on their profile?

    What would be the query to determine that?

    Thanks!
    PowWows.com

  • #2
    Try this...
    Code:
    SELECT 
        user.username, 
        count( visitormessage.vmid ) AS vmcount
    FROM 
        visitormessage
    LEFT JOIN 
        user ON visitormessage.userid = user.userid
    GROUP BY 
        user.username
    ORDER BY 
        vmcount DESC 
    LIMIT 
        20
    Lats...

    Comment


    • #3
      Thanks!

      Try running this via vB Control Panel - no results.
      PowWows.com

      Comment


      • #4
        Try the alternative - phpmyadmin
        Lats...

        Comment


        • #5
          Won't make a difference.

          Did you add your table prefix in?

          Comment


          • #6
            Originally posted by Dilly View Post
            Won't make a difference.

            Did you add your table prefix in?
            Surprisingly, it actually would make a difference. http://www.vbulletin.com/forum/showthread.php?t=289226
            Regards,
            Nick

            Comment


            • #7
              In that case, it's a bug.

              Comment


              • #8
                Reported.
                ~~~~~

                Comment


                • #9
                  The query works just fine in the ACP, without the vertical spacing. I just post it like that for clarity.
                  Lats...

                  Comment


                  • #10
                    Yes, vBulletin does some manipulation of the query string before execution, but the newlines cause their manipulation to fail in some cases.
                    ~~~~~

                    Comment

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