reasons for slow loading page
-
One of the pages in my application is taking a lot longer then another page to load. Is there an easy way to check why this is? I have a gridview which is populated but that is only two pages long. Also when I use on row create, any factor I set for a row works apart from the last row in the page. If i put the same code in the row data bound it works on every row. why is this?
-
One of the pages in my application is taking a lot longer then another page to load. Is there an easy way to check why this is? I have a gridview which is populated but that is only two pages long. Also when I use on row create, any factor I set for a row works apart from the last row in the page. If i put the same code in the row data bound it works on every row. why is this?
The slow page, is it making use of the GridView? If true: Where is the data from the GridView coming from? It SQL Server, which version? Is the data coming from a query, stored procedure, or where? Is the GridView making use of Paging?
-
One of the pages in my application is taking a lot longer then another page to load. Is there an easy way to check why this is? I have a gridview which is populated but that is only two pages long. Also when I use on row create, any factor I set for a row works apart from the last row in the page. If i put the same code in the row data bound it works on every row. why is this?
eyeseetee wrote:
One of the pages in my application is taking a lot longer then another page to load
If you are getting the data from a database it could be a database problem. Try running the same query on the database to see how long it takes to run. If it is slow, the table indexes may not be setup correctly.
eyeseetee wrote:
apart from the last row in the page
Do you mean last data row or footer row?
-
The slow page, is it making use of the GridView? If true: Where is the data from the GridView coming from? It SQL Server, which version? Is the data coming from a query, stored procedure, or where? Is the GridView making use of Paging?
cyber-drugs wrote:
The slow page, is it making use of the GridView?
Yes it is making use of Gridview
cyber-drugs wrote:
Where is the data from the GridView coming from?
SQL Server
cyber-drugs wrote:
It SQL Server, which version?
2003
cyber-drugs wrote:
Is the data coming from a query, stored procedure, or where?
Both, Im also running checks on the rows when the page loads
cyber-drugs wrote:
Is the GridView making use of Paging?
yes :)
-
eyeseetee wrote:
One of the pages in my application is taking a lot longer then another page to load
If you are getting the data from a database it could be a database problem. Try running the same query on the database to see how long it takes to run. If it is slow, the table indexes may not be setup correctly.
eyeseetee wrote:
apart from the last row in the page
Do you mean last data row or footer row?
-
cyber-drugs wrote:
The slow page, is it making use of the GridView?
Yes it is making use of Gridview
cyber-drugs wrote:
Where is the data from the GridView coming from?
SQL Server
cyber-drugs wrote:
It SQL Server, which version?
2003
cyber-drugs wrote:
Is the data coming from a query, stored procedure, or where?
Both, Im also running checks on the rows when the page loads
cyber-drugs wrote:
Is the GridView making use of Paging?
yes :)
ICT, There is no SQL Server 2003, there is 2000 and 2005, so can I presume you are on 2000? If so, that would be why your page is slow, or at least my presumption without in deptch analysis! SQL Server 2000 cannot handle "real paging", it gives you the effect of paging, when in fact it pulls down every single record from your query, and then when all the data from the database hits the .NET web server, this will cut up the data and make it appear as if you are getting paging. In SQL Server 2005, they added the feature "Row Numbering", which allows you to get true paging, so when you ask for the first 100 records in a table, starting from record 101, it gives you just 100 records, where-as 2000 would of given you every single record. The way to confirm this, if you run query analyser and run a trace on the database being used, and find the query being fired to the database by your GridView. After you have this query, try running it manually in query analyser. If this query runs as slow as your page takes to load, we have identified your problem. :) The easiest solution would be to upgrade to SQL Server 2005 or above.
-
Last data row for the current page, so say there is 3 pages, the last row on each is not the same as the others in formatting.
How are you formatting the rows?
-
ICT, There is no SQL Server 2003, there is 2000 and 2005, so can I presume you are on 2000? If so, that would be why your page is slow, or at least my presumption without in deptch analysis! SQL Server 2000 cannot handle "real paging", it gives you the effect of paging, when in fact it pulls down every single record from your query, and then when all the data from the database hits the .NET web server, this will cut up the data and make it appear as if you are getting paging. In SQL Server 2005, they added the feature "Row Numbering", which allows you to get true paging, so when you ask for the first 100 records in a table, starting from record 101, it gives you just 100 records, where-as 2000 would of given you every single record. The way to confirm this, if you run query analyser and run a trace on the database being used, and find the query being fired to the database by your GridView. After you have this query, try running it manually in query analyser. If this query runs as slow as your page takes to load, we have identified your problem. :) The easiest solution would be to upgrade to SQL Server 2005 or above.
cyber-drugs wrote:
The way to confirm this, if you run query analyser and run a trace on the database being used, and find the query being fired to the database by your GridView. After you have this query, try running it manually in query analyser. If this query runs as slow as your page takes to load, we have identified your problem.
How do I do this then? thanks