Solved

Session State Asp Temp Session db

Posted on 2011-03-10
4
427 Views
Last Modified: 2013-11-08
Q.SessionID is hashed and too lengthy for us to use as a unique identifier. How can we add or
use a short number which serves the same purpose as the sessionID?
0
Comment
Question by:ckrafthofer
  • 2
  • 2
4 Comments
 
LVL 17

Accepted Solution

by:
ToAoM earned 250 total points
Comment Utility
What do you want to use this identifier for? And do you want to access it only from the database? Or also from the ASP.NET code?

It would be reasonably simple to put a numeric column in the session table with a trigger which fills it upon creation (for security purposes you want this to be a unique random number). Or, if you're never exposing this ID externally, you could use an identity column.

Something else I'd like to know is how/why the unique id in SessionId is too long for your purposes?
0
 

Author Comment

by:ckrafthofer
Comment Utility
Well, we need smaller number in order to track the user's movement thru several sections in our website and they have their own navigational db.
0
 
LVL 17

Expert Comment

by:ToAoM
Comment Utility
why can't you use the sessionid from the default asp.net db then?

If you only need to track them while the session is live and when you don't need access to it directly in the database, why not put a value in the session in the global.asax and read that?
0
 

Author Closing Comment

by:ckrafthofer
Comment Utility
His additional information was also accurate..about global.asax
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

In my previous article (http://www.experts-exchange.com/Programming/Languages/.NET/.NET_Framework_3.x/A_4362-Serialization-in-NET-1.html) we saw the basics of serialization and how types/objects can be serialized to Binary format. In this blog we wi…
A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now