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
 Site Stat MOD MS JET DB Engine error '80040e10'
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

ikalota
Starting Member

37 Posts

Posted - 08 November 2004 :  15:23:11  Show Profile
Hi all,

I am getting the following error with this MOD, but it is not consistent. If I press the browser refresh button, the error goes away and the stats are displayed. But I always get the error on the exact same line.
Does anyone have any idea as to Why it is happening? I am displaying Site Stats on the inc_site_left.asp. I have the Site Integration Mod installed. It was also happening when I moved the Site Stats from inc_site_left.asp to the centre of my portal page.

Here is the code that is causing error:

'We get the Total Day Visit
If strTotalDayVisitor = "1" then
strSql = "SELECT SITESTAT_DAY_Visitor AS Day_Visit
FROM " & strMemberTablePrefix & "SITESTAT
WHERE (((SITESTAT_YEAR)=" & strSS_Year & ") AND
((SITESTAT_MONTH)=" & strSS_Month & ") AND
((SITESTAT_TODAY)=" & strSS_Day & "))"
set rs = my_conn.execute(strSql,adOpenStatic,adCmdTxt)
DAY_Visit=rs("DAY_Visit")
End If

Thanks in advance.

Microsoft JET Database Engine error '80040e10'

No value given for one or more required parameters.

/snitz/inc_sitestat.asp, line 350


[edit]moved to correct forum[/edit]

Edited by - davemaxwell on 13 November 2004 16:51:36

laser
Advanced Member

Australia
3859 Posts

Posted - 08 November 2004 :  16:07:44  Show Profile
A link to see this in action would be good, but I'm guessing line 350 is :

DAY_Visit=rs("DAY_Visit")

and the problem only arises when there is nothing returned in the SQL statement. To fix it, add these lines above & below my guess at line 350, to make it look like this :


If not rs.BOF and not rs.EOF then
    DAY_Visit=rs("DAY_Visit")
End If


Let me know if it works.
Go to Top of Page

ikalota
Starting Member

37 Posts

Posted - 11 November 2004 :  13:35:21  Show Profile
Hi laser,

Thanks for your help. I tried adding the code u suggested but it didn't help. Anyways, I think, I figured out the problem. The code is using mixed case i.e. the actual field/column names in the table are all Upper case and the code was using field names with mixed cases: please see below:

strSql = "SELECT SITESTAT_DAY_Visitor AS Day_Visit
FROM " & strMemberTablePrefix & "SITESTAT
WHERE (((SITESTAT_YEAR)=" & strSS_Year & ") AND
((SITESTAT_MONTH)=" & strSS_Month & ") AND
((SITESTAT_TODAY)=" & strSS_Day & "))"
set rs = my_conn.execute(strSql,adOpenStatic,adCmdTxt)
DAY_Visit=rs("DAY_Visit")

The highlighted red should have been in Upper case while the highlighted blue should have been in the lower case.

After this fix, I havent gotten this error at all. It seems like that was it and it is working fine now. I made these changes couple days ago and havent gotten any errors since whereas I was getting this error quite a few times during a day.

Go to Top of Page

laser
Advanced Member

Australia
3859 Posts

Posted - 11 November 2004 :  14:47:08  Show Profile
Interesting ... ASP shouldn't be case sensitive, or maybe and I always use lower-case. But I'm glad it works anyway
Go to Top of Page

ikalota
Starting Member

37 Posts

Posted - 13 November 2004 :  01:05:11  Show Profile
Yup... I think you are right. I believe ASP is not case sensitive. BUT you know what I think MS Access is perhaps case sensitive, because the table column name being used was in mixed case.

The good thing is that the change is DEFINITELY working. I have not seen a single error since the change.

Go to Top of Page

PeeWee.Inc
Senior Member

United Kingdom
1893 Posts

Posted - 13 November 2004 :  06:44:21  Show Profile  Visit PeeWee.Inc's Homepage
If i remember right, in some cased ASP is case senitive.

De Priofundus Calmo Ad Te Damine
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 1.29 seconds. Powered By: Snitz Forums 2000 Version 3.4.07