I know I need to use the using statement to use a database connection, to be sure that it will be automatically closed without further worries.
But I am using a masterpage and a content page which both are needing to retrieve data from a the dataabse, and both have their own using statement. So for every request, I am still using two database connections.. How can that be prevented? I would like to be using one database connection only for each request.
And there is a special case: I also use caching, so in some cases there is no need to have a database connection at all, since the data is retrieved from the cache. So then I would want that no database connection is created at all...
I could not find any practical solution or example about this.. can anybody give me a hint?