Solved

Creating a session table

Posted on 2014-09-24
6
90 Views
Last Modified: 2014-09-26
Sorry for the novice question here. I'm working on a database design and I'm trying to figure out how to create a session table. For example, if someone logs into the application and then gets timed out, how can I keep their session login information so when they come back to the application it remembers who they are and can take them right back to where they were in the application. Is there an article that explains how to create/store a users session information for retrieval and bringing them back to the application where they were and continuing where they left off?  See the embedded image for the current design.

database diagram
Thanks for any help.
Regards
0
Comment
Question by:-Dman100-
  • 3
  • 2
6 Comments
 
LVL 82

Expert Comment

by:Dave Baldwin
Comment Utility
What 'session' are you referring to?
0
 

Author Comment

by:-Dman100-
Comment Utility
Hi Dave,

Thank you for replying to my post.  My apologies if my explanation wasn't clear.  I was referring to the user session when a user logs into the application.  Does this help explain a little better?
0
 
LVL 82

Expert Comment

by:Dave Baldwin
Comment Utility
Only slightly.  How is the user logging in?  What kind of application?  Is it a web page on a web server?  While web servers set up 'sessions', I don't remember SQL server doing that.  You have to know what is setting up the session before you can capture any info about it.
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 

Author Comment

by:-Dman100-
Comment Utility
It is going to be a VB.NET web application.  Now, we are still determining if we will store the username/password in a sql table, but it will be a web application on a web server.
0
 
LVL 82

Expert Comment

by:Dave Baldwin
Comment Utility
If you are going to have remote users logging in, a username/password table would be the most common way of doing that.  I don't know how to save and restore ASP session name and info on IIS.  I've done it on PHP but for the data, it would require putting the data into the data base since the session variables disappear when the session expires.
0
 
LVL 1

Accepted Solution

by:
aneesa83 earned 500 total points
Comment Utility
The session state provider is configured in your web.config using the sessionState element. For SQL server you set the mode to SQLServer and configure a connection string.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

763 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

11 Experts available now in Live!

Get 1:1 Help Now