Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: MOD Implementation
 Events Calendar help
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  14:03:12  Show Profile  Send bobbart an ICQ Message
I made changes to get it to work with 3.4. After a few changes as listed in the topics below its working but the Past and Recent events are not being displayed in the test area under the small calendar.

Here are the topics that guided me so far.

http://forum.snitz.com/forum/topic.asp?TOPIC_ID=32882

http://forum.snitz.com/forum/topic.asp?TOPIC_ID=34582

I am reposting this in here under direction from Davio to try and get help.

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 September 2002 :  14:31:08  Show Profile
Post a link to the page where you are testing it. Post the sql which is being generated before it is executed. You can do so by Inserting
Response.write (strSql)

Just before the statement where you connect to the database to get the records.

CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain

It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.

Prayer Of Forgiveness
"I forgive all living beings. May all living beings forgive me!
I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated)
Go to Top of Page

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  14:53:27  Show Profile  Send bobbart an ICQ Message
SELECT event_id, start_date, event_title, PRIVATE, M_NAME FROM GSURU_EVENTS INNER JOIN GSURU_MEMBERS ON GSURU_EVENTS.added_by = GSURU_MEMBERS.MEMBER_ID WHERE start_date < '20020911000000' AND start_date > '20021011000000' ORDER BY start_date ASC LIMIT 15 There are no new events for upcoming month


Thats what I get when I add that.

Edited by - bobbart on 11 September 2002 15:40:40
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 September 2002 :  15:24:09  Show Profile
Have you checked if there are events in the DB with dates between 20020812000000 and 20020911000000. Post few dates from the DB.

CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain

It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.

Prayer Of Forgiveness
"I forgive all living beings. May all living beings forgive me!
I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated)
Go to Top of Page

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  15:41:51  Show Profile  Send bobbart an ICQ Message
I corrected my above post. It was doing the past dates and not the current.

But now it is doing the current and there are events for the dates checked.
Go to Top of Page

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  15:45:20  Show Profile  Send bobbart an ICQ Message
humm its something to do with the Upcoming because I can get the pastevents to show.

Edited by - bobbart on 11 September 2002 15:55:48
Go to Top of Page

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  15:49:49  Show Profile  Send bobbart an ICQ Message
Here is the code

function DisplayUpcomingEvents
	strSql = "SELECT event_id, start_date, event_title, PRIVATE, " 
strSql = strSql & strDBNTSQLName & " FROM " & strTablePrefix & "EVENTS " 
strSql = strSql & "INNER JOIN " & strMemberTablePrefix & "MEMBERS "
strSql = strSql & "ON " & strTablePrefix & "EVENTS.added_by = " 
strSql = strSql & strMemberTablePrefix & "MEMBERS.MEMBER_ID "
strSql = strSql & "WHERE start_date < '" & DateToStr(date()) & "' "  
strSql = strSql & "AND start_date > '" & DateToStr(DateAdd("d",30,date())) & "' "
strSql = strSql & "ORDER BY start_date ASC"
'Following Statement is for MySql DB Users
strSql = strSql & " LIMIT " & intDisplay & " "
%>

and

function DisplayPastEvents
strSql = "SELECT event_id, start_date, event_title, PRIVATE, " 
strSql = strSql & strDBNTSQLName & " FROM " & strTablePrefix & "EVENTS " 
strSql = strSql & "INNER JOIN " & strMemberTablePrefix & "MEMBERS "
strSql = strSql & "ON " & strTablePrefix & "EVENTS.added_by = " 
strSql = strSql & strMemberTablePrefix & "MEMBERS.MEMBER_ID "
strSql = strSql & "WHERE start_date < '" & DateToStr(date()) & "' "  
strSql = strSql & "AND start_date > '" & DateToStr(DateAdd("d",-30,date())) & "' "
strSql = strSql & "ORDER BY start_date DESC"
'Following Statement is for MySql DB Users
strSql = strSql & " LIMIT " & intDisplay & " "
	%>

Edited by - bobbart on 11 September 2002 16:16:21
Go to Top of Page

bobbart
Junior Member

USA
163 Posts

Posted - 11 September 2002 :  16:16:47  Show Profile  Send bobbart an ICQ Message
Got it.
Thanks
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 11 September 2002 :  16:47:07  Show Profile
You had the contradicting criteria in the Where Clause, use the following code to get the upcoming events.

function DisplayUpcomingEvents
	strSql = "SELECT event_id, start_date, event_title, PRIVATE, " 
strSql = strSql & strDBNTSQLName & " FROM " & strTablePrefix & "EVENTS " 
strSql = strSql & "INNER JOIN " & strMemberTablePrefix & "MEMBERS "
strSql = strSql & "ON " & strTablePrefix & "EVENTS.added_by = " 
strSql = strSql & strMemberTablePrefix & "MEMBERS.MEMBER_ID "
strSql = strSql & "WHERE start_date >= '" & DateToStr(date()) & "' "  
strSql = strSql & "AND start_date < '" & DateToStr(DateAdd("d",30,date())) & "' "
strSql = strSql & "ORDER BY start_date ASC"
'Following Statement is for MySql DB Users
strSql = strSql & " LIMIT " & intDisplay & " "
%>

CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain

It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.

Prayer Of Forgiveness
"I forgive all living beings. May all living beings forgive me!
I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated)
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.4 seconds. Powered By: Snitz Forums 2000 Version 3.4.07