G
Guest
Hi,
I have an application with a GridView with a data source of a stored
procedure in MS SQL Server 2005.
The stored procedure is going against a large encrypted table, so is memory
and processing intensive. However, the stored procedure does run in an
acceptable time (about 2 to 3 seconds). I can run the stored procedure back
to back in a query with no degradation of performance. The stored procedure
takes some search parameters.
However, when I run it in vb.net, the datagrid loads fine on the first load,
but if I change a search criteria and reload it timeouts, even though the
result set in the second instance is smaller than the first instance (timeout
is on the gridview databind function).
My question is, how do I get around this? Apparently memory is getting used
and not released or something, but so much of the gridview is hidden in
version 2, I don't see a way to clear it, or close and reopen a connection or
any such. I've tried limiting the result set to as low as 5 rows (using top
in the stored procedure), but that makes no difference. If I cut the table
size the stored procedure runs against way down though, it all runs fine.
Apparently, going through .net to the stored procedure trashes memory, which
doesn't happen when the stored procedure is run in a query window in sql
server.
Can you advise me on this?
Thanks.
I have an application with a GridView with a data source of a stored
procedure in MS SQL Server 2005.
The stored procedure is going against a large encrypted table, so is memory
and processing intensive. However, the stored procedure does run in an
acceptable time (about 2 to 3 seconds). I can run the stored procedure back
to back in a query with no degradation of performance. The stored procedure
takes some search parameters.
However, when I run it in vb.net, the datagrid loads fine on the first load,
but if I change a search criteria and reload it timeouts, even though the
result set in the second instance is smaller than the first instance (timeout
is on the gridview databind function).
My question is, how do I get around this? Apparently memory is getting used
and not released or something, but so much of the gridview is hidden in
version 2, I don't see a way to clear it, or close and reopen a connection or
any such. I've tried limiting the result set to as low as 5 rows (using top
in the stored procedure), but that makes no difference. If I cut the table
size the stored procedure runs against way down though, it all runs fine.
Apparently, going through .net to the stored procedure trashes memory, which
doesn't happen when the stored procedure is run in a query window in sql
server.
Can you advise me on this?
Thanks.