PDA

View Full Version : ASP Session or Db-calls


Daniel
06-05-02, 08:16
Hello!

What will give me the best performance?
On Session_onStart calling my Db and fetching all the data I need and then just refer to these recordsets throughout the whole session using the filter prperty to filter out the data I need
or is it it better to just call the Db evertime I need the data?

Grateful for any answer
Daniel Martinsson

Khalid
06-07-02, 15:50
I think you should call your records every time a page is requested, because ASP is cookies based.
The session it self is nothing but a cookies generated when a session starts, and a unique random number is generated to identify the client's session variables.

Now, if ASP is going to do the same process for you every time, I suggest not trusting it, and do you work every time.

This is my personal opnion and I am using it.

Remember to destroy every object you create.

Hope this helps