Print Page | Close Window

Last Post date

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=18854
Printed Date: 12 April 2026 at 10:15pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Last Post date
Posted By: Ravage
Subject: Last Post date
Date Posted: 22 March 2006 at 11:51am
Hey all
 
Can I ask a quick question?
 
When your in the forum theres obviously the last posted column.
I'm working on inserting rows into both tblthread and tbltopic (more on that later)...
 
Basically to me this field in pseudo sql code would be:
 
select max(message_date) from tblthread where topic_id = @<variable>
 
Now i'm filling this tblthread.message_date field properly, but for some reason the forum page isnt using my sql but must be looking elsewhere...
Without working out what page is doing what in your forum asp scripts, I was wondering if your writing to the dtabas base the last updated date for each topic and I'm just missing it!?!?!?
 
Thanks in advance!
 
Oh, yeah, why am I doing this? Well we're migrating from egroups (eww) to web wiz, so if some adds something on egroups it automatically get added to the forums. This helps with migrations of some 400 members.
 
It also works if people basically want to email into a forum. I'll start a topic in the mods section once I have got that far as I've seen posts asking to import outlook /exchange/etc data into forums! 90% there, I think this is the last bit!



Replies:
Posted By: WebWiz-Bruce
Date Posted: 22 March 2006 at 12:05pm
Is this version 7.x you are using?

In version 8 (this is the version 8 support forum), the date fields in the tblTopic table have been dropped and are no-longer used, except for event dates to do with the calendar system, but I doubt you need to know this for what you are doing..


Posted By: Ravage
Date Posted: 22 March 2006 at 12:16pm
Yeah, I'm using version 8. Hope that wasnt a mistake :)
 
I've been looking at forum_topic.asp since posting but frankly the asp is too deep for me ;) No idea how your getting that last post date!
 
Perhaps best if I show you my work:
http://www.ukvac.com/forum/forum_topics.asp?FID=13 - http://www.ukvac.com/forum/forum_topics.asp?FID=13
 
Excusing my dribble for subjects and message bodies (this is temporary text I'm working with but I realise I'm swearing like a trooper in it!)
 
If I refer you to the post with 7 replies (Git? Whose a Git? - see unethical data sorry!). you can see its saying last post is 9:07am, but if you open up the topic, you'll see the last reply is 11:29am
 
Conversely, if you look at the top topic (name [UKVAK] beta 6) the last post date is 11:36am. This post was done using the wbeb wiz forum post reply (i.e. using your code not my dodgy imports ;P)
 
So yeah, just trying to see if I can update the LastPosted date field you are using in the database so that in the first example the date says 11:29 not 9:07....
If  you are getting it via the asp or sessions or whatever then yeah, no hope I think to sort this.
 
Thanks for your help mind you! wow! quick response!!


Posted By: WebWiz-Bruce
Date Posted: 22 March 2006 at 12:25pm
Are you using an upgraded 7.x database?

If so there are two date fields in the tblTopic table, one for  Start_date and the other for Last_entry_date.

These two fields are no longer used in version 8 and can be safly deleted from the database.


Posted By: WebWiz-Bruce
Date Posted: 22 March 2006 at 12:29pm
Instead in version 8 you have two new fields:-

1. Start_Thread_ID - data type = interger
2. Last_Thread_ID - data type = interger

These fields hold the value of tblThread.Thread_ID for the first and last posts in the topic, this is how the SQL makes the table join to get the data to display for the first and last post data in the topic index


Posted By: Ravage
Date Posted: 22 March 2006 at 12:30pm
Originally posted by -boRg- -boRg- wrote:

Are you using an upgraded 7.x database?
 
No, I installed 8 last night, and been working on it since :)
 

Originally posted by -boRg- -boRg- wrote:

If so there are two date fields in the tblTopic table, one for  Start_date and the other for Last_entry_date.

These two fields are no longer used in version 8 and can be safly deleted from the database.
 
Nope, only datefields I've got is tblTopic.Event_date, but as you say thats all filled with NULLs.
 
Only other date field I looked at is tblThread.message_date which is as I say, what I guessed your forum_topic.asp was looking at.
Thanks, Rav


Posted By: Ravage
Date Posted: 22 March 2006 at 2:12pm
Many thanks, cracked it with your help!



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net