Author |
Topic  |
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 27 December 2002 : 22:35:46
|
Yes, I saw it and it times out after recordcount. For some reason pagesize and pagecount properties are not accessible and that is probable cause of error. I will try to find out any refernce to this behaviour. Thanks for your patience and effort. |
 |
|
RichardKinser
Snitz Forums Admin
    
USA
16655 Posts |
Posted - 27 December 2002 : 22:45:08
|
if I put Response.End like shown below:
rs.pagesize = clng(strPageSize)
Response.write "RecCount : " & rs.recordcount & "<BR>"
Response.write "PageSize: " & rs.PageSize & "<BR>"
Response.write "PageCount: " & rs.PageCount & "<BR>"
Response.End
maxpages = (rs.pagecount)
rs.absolutepage = mypage '** then it shows all 3 (RecCount, PageSize, Pagecount) if it doesn't time out first. I have gotten it to show all 3 without timing out, but when it does time out, it seems to be timing out when trying to display the PageSize. |
 |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 27 December 2002 : 22:54:19
|
I also saw members page loaded with the following information at the top RecCount : 16714 PageSize: 25 PageCount: 669
Something to do with the pagecount property. However, I have no clue to the behavior other than that. Was there any upgrades or updates on the server recently?
You could also try to initialize maxpages = 0 and then maxpages = rs.PageCount |
 |
|
RichardKinser
Snitz Forums Admin
    
USA
16655 Posts |
Posted - 27 December 2002 : 23:01:03
|
I don't know if any upgrades or updates have been done, we'd have to ask Huw about that. |
 |
|
HuwR
Forum Admin
    
United Kingdom
20600 Posts |
Posted - 28 December 2002 : 04:03:04
|
No there have been NO upgrades, besides if it was server related it would affect all the Snitz forums using the SQL and it is not, it is only affecting it here. |
 |
|
Jeepaholic
Average Member
  
USA
697 Posts |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
davemaxwell
Access 2000 Support Moderator
    
USA
3020 Posts |
Posted - 29 December 2002 : 23:01:46
|
Is this the same members.asp included in the standard release?
If not, then just out of curiousity, will the query causing problems run in Query Analyzer against the current database? I had a situation a while ago where I actually had an invalid query (a field I was querying on didn't exist on the database), but instead of giving me an error on the query, it just kept timing out. I was pulling my hair out until I looked at the exact query I was running and determined which portion was erroring out. I think it's a bug in SQL2K since that was the box I was running on when it errored out.... |
Dave Maxwell Barbershop Harmony Freak |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 29 December 2002 : 23:46:43
|
I tested the query that gives the timeout with some care. It works perfectly in Query Analizer and I made sure it was the same query, by using the output of a Response.Write in QA. The problem there is really the time the query needs to complete when there are many posts to analize (there were about 200,000 of them). If the recordset type and lock type could be changed, the problem could be made to go away, but the need for paging removes that as a choice.
I spent some time with this but I've been unable to find a solution. I also failed to find any links to posts that provided solutions to this. The most recommended solutions for this, changing the values of the CommandTimeout and ConnectionTimeout properties didn't provide a fix, contrary to what was expected... |
Snitz 3.4 Readme | Like the support? Support Snitz too |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 29 December 2002 : 23:50:03
|
I guess we're talking about different situations, me and Richard. He's talking about the query from members.asp and I was talking about the issue raised by Jeepaholic, about search.asp.
Just wanted to make that clear. |
Snitz 3.4 Readme | Like the support? Support Snitz too |
 |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 30 December 2002 : 07:12:23
|
We can also use getrows to get specific records from the recordset.
.getRows(NumberofRows,StartingRow)
for example:
.getRows(25,1) -Page One
.getRows(25,26)-Page Two
It will, though, require to check if the starting record exists. |
 |
|
Gremlin
General Help Moderator
    
New Zealand
7528 Posts |
Posted - 30 December 2002 : 07:55:06
|
Doesn't members.asp already only get the required number of records (PageSize) via GetRows() ?
I must admit I've not read this thread fully but at a glance it seems the GetRows isn't the issue anyway. |
Kiwihosting.Net - The Forum Hosting Specialists
|
 |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 30 December 2002 : 08:04:53
|
GetRows is not the issue. Timeout occurs when trying to populate maxpages using rs.PageCount maxpages = rs.PageCount |
 |
|
GauravBhabu
Advanced Member
    
4288 Posts |
Posted - 30 December 2002 : 08:12:23
|
However, AFAIK, GetRows does not behave according to PageSize. For example say you have 25 records. If you specify Pagesize = 15, GetRows will still get all 25 records unless specified otherwise.
|
Edited by - GauravBhabu on 30 December 2002 08:40:21 |
 |
|
HuwR
Forum Admin
    
United Kingdom
20600 Posts |
Posted - 30 December 2002 : 09:07:05
|
it is cachesize which governs how many records are fetched, not the pagesize, if you set cachesize to 15 and pagesize, it will only fetch 15 records, not the whole 25.
|
 |
|
Topic  |
|