News:

Wondering if this will always be free?  See why free is better.

Main Menu

[4730]Remove "Topics and Posts" doesn't work?

Started by Felix J, May 24, 2011, 12:19:51 PM

Previous topic - Next topic

Felix J

Here is information about it - http://www.simplemachines.org/community/index.php?topic=434970.0

If any support specialist wanna take a look I can give you login info via pm.

mashby

I'm game (as in curious). I'll await your PM and hope I can assist you.
Always be a little kinder than necessary.
- James M. Barrie

Felix J

I was feeling really sick yesterday so I had to sleep almost the whole day, but now it's better.

I've sent you the login information.

Thanks!

Felix J

I don't know if this functon works when not connecting the posts to a new user and just deleting the topics and posts from the original user. Since I haven't tried this. Only tried it after connecting the topics and posts to a new user.

emanuele

#4
As far as I can see it's a bug.

SMF doesn't delete the topics reassigned to another used.

Reproduced in a freshly installed SMF 2.0 RC5.
The problem should be that the topics are not "reassigned" to the new user (id_member_started) and then when it's time delete them SMF fails because the id of the reassigned member is not the same as the id of the id_member_started now 0.

Edit
This query:
$smcFunc['db_query']('', '
UPDATE {db_prefix}topics as t, {db_prefix}messages as m
SET t.id_member_started = {int:memID}
WHERE m.id_member = {int:memID}
AND t.id_first_msg = m.id_msg',
array(
'memID' => $memID,
));


at the end of the function reattributePosts, just before the return should fix it. :) (don't have any idea how it works on big databases! ;))


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Felix J

Quote from: emanuele on May 26, 2011, 11:29:02 AM
As far as I can see it's a bug.

SMF doesn't delete the topics reassigned to another used.

Reproduced in a freshly installed SMF 2.0 RC5.
The problem should be that the topics are not "reassigned" to the new user (id_member_started) and then when it's time delete them SMF fails because the id of the reassigned member is not the same as the id of the id_member_started now 0.

OK!

Good to know. Thanks

IchBin™

In case you missed it Felix, emanuele updated his last post with a fix. Looks like you guys posted almost at the same time. :)
IchBin™        TinyPortal

Felix J

#7
Quote from: IchBin™ on May 26, 2011, 11:53:26 AM
In case you missed it Felix, emanuele updated his last post with a fix. Looks like you guys posted almost at the same time. :)

Yes I saw it, but thanks anyway.



emanuele, so your fix covers both the options "All Posts" and "Topics and Posts" as well when topics or/and posts gets removed from the poster in which made the threads and posts?

(I don't know if the same issue comes after deleting threads and/or posts from the original poster...) so this would be good to know aswell..

Will it also be possible to just remove posts but not threads with this fix choosing the option "All Posts"?


Last but not least... lets say a user spam with just making threads... and you choose the option "All Posts". What will be happen then? Should the admin choosing the option get an message saying it isn't possible or something like that? Since that option should only remove posts and not threads?


Felix J

#8
Anyone that can say for sure if the feature option "All Posts" works? and if both the options would work for the original poster aswell. This is a little offtopic I know, but it's very close to this one.

Yes all posts works for the user connected to posts... I will check the other one.


Forget my earlier message.

OK everything else in this area seems to be working after testing. Great! Then only this one.

emanuele



Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Illori

moving to bogus board as duplicate of the other thread

Advertisement: