Announcement

Collapse
No announcement yet.

Replacing an original poster with another

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

  • Replacing an original poster with another

    I have a press release forum which posts press releases automatically through a certain user account.

    Is there a way I can change the thread starter for the entire press release forum from one user to another.

    For example, user "John" has posted all current press releases up until this date, now I would like to change the OP from "John" to "Dave" in the entire Press Release forum only.

    Is this possible?

  • #2
    Try this...
    Code:
    UPDATE 
        post
    LEFT JOIN
        thread 
    ON
        post.threadid = thread.threadid
    SET 
        username = 'Dave',
        userid = X
    WHERE
        thread.forumid = Y
    AND
        post.username = 'John'
    Change X to Dave's userid and Y to your Press Release forumid.
    Lats...

    Comment


    • #3
      Originally posted by Lats View Post
      Try this...
      Code:
      UPDATE 
          post
      LEFT JOIN
          thread 
      ON
          post.threadid = thread.threadid
      SET 
          username = 'Dave',
          userid = X
      WHERE
          thread.forumid = Y
      AND
          post.username = 'John'
      Change X to Dave's userid and Y to your Press Release forumid.
      Thanks but where do enter this code at?

      Comment


      • #4
        Originally posted by CrashPush View Post
        Thanks but where do enter this code at?
        Admin CP -> Maintenance -> Execute SQL Query -> Manual Query

        Be sure to backup your database before you execute a query.

        Comment


        • #5
          Also, how to run a query.

          You will also need to update forum counters once run.
          Lats...

          Comment


          • #6
            Worked great thank you very much Lats. But the forum display still shows "John" as the thread author/starter and not "Dave". When you open and read the thread it does show "Dave" as the author/starter.

            Is there any way to change that so on the forum display it shows "Dave" as the thread author/starter?

            I ran the forum counters and nothing.

            Comment


            • #7
              Dang, didn't scroll far enough right on the thread table.

              Try this...
              Code:
              UPDATE
                  thread
              SET
                  postusername = 'Dave',
                  postuserid = 'X'[COLOR=red],
                  lastposter = 'Dave'[/COLOR]
              WHERE
                  postusername = 'John'
              AND
                  forumid = 'Y'
              You will not need the red code if people respond to the thread, otherwise you can leave it in.
              Lats...

              Comment


              • #8
                Awesome! Thanks a lot Lats!

                Comment

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