Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
165 views
in Q2A Core by
Without losing the ability to reasonable easy upgrade, when new versions of Q2A are released, how difficult is it to create a new table that is accessed for a new feature I develop?  I realize the naming need be something statistically improbable to ever be used by the Q2A core!

(If an upgrade [to Q2A] may potentially mess with the table, then would creating a separate database be better?)

There are several things I have in mind, but one, for example, (that could be done other ways, but this seems the most efficient w/a large database and many users OL @ a given time) is to show the individuals w/the highest number of posts w/in the past 24 hours.  Now, the past 24 hours, clearly doesn't mean at midnight the whole thing is just reset!  Rather, If member-1 posts one question at 3am, one answer at 6pm and another answer at 1 am the next day, they will be listed all of the first day from 3am on (unless they are pushed off the bottom of the 'stack' of, say 10 listed 'top-posting members'  showing "1 post" between 3am and 6pm, where it would become "2 posts" until 1 am the next morning, where it would read "3 posts".  Then a few hours later at 3am, the 24-hour time will have expired on the first post, thus it would read "2 posts" (assuming they post no more), and at 6pm it would similarly decrement to "1 post" and assuming nothing new was posted by 1am the following morning, they would drop off the list (assuming they even had made to to the top ten 'top-posters' somewhere along the line!

I simply though each new "post", meaning: Q or A, could place an entry into a table with the userID, the timeDate (either of post time or of expiration time), then anytime the page was loaded, it would use this relatively small table to, first, delete any expired posts from that list, then, assemble the list determining a post-count for each user in the list, and, finally, see who makes the top ten cut, and then display those on the current page.  (I suppose ties can be broken based on who had the earliest post or something trivial like that.)

Is this a reasonable solution to work out what I'm trying to do, or what better advise/corrections can you provide?  Am I warm?

Thank you for taking the time to read my explanation!
Q2A version: 1.7.4
by
OK, fair enough,... But, is it too complicated to reasonably understand OR to complicated to reasonably implement?  I can reword it OR re-design the idea,....


[ Or you can simply say, shud'up I've given you plenty of help already!  (I'm kidding, but not necessarily!!  LOL!) ]  (a simple " Wha' " would do in the former case and a 'keep it concise' would work in the latter!)...

Please log in or register to answer this question.

...