Database table used in one session

Posted on 2004-11-19
Last Modified: 2010-04-01
I want users of webpage to use a table but when they close the webpage, all the stuff they add to a table in a SQL database should be automatically deleted. How can i possibly do that in jsp?
Question by:VbMonk
    1 Comment
    LVL 2

    Accepted Solution

    What database are you using?

    If you are using SQL Server, you could write a job that would truncate all of the data from that table periodically.  Would that work?

    If the data the users are entering is only intended to be used during the time they are on the page, instead of writing that data to a database table you could store it in objects in the session.
    That way there is no interaction with the datbase at all, and the data will dissappear when the user leave the site closes the brower.

    Hope that helps.

    Featured Post

    Gigs: Get Your Project Delivered by an Expert

    Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

    Join & Write a Comment

    Suggested Solutions

    Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
    When we have a dead host and we lose all connections to the ESXi, and we need to find a way to move all VMs from that dead ESXi host.
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    755 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

    17 Experts available now in Live!

    Get 1:1 Help Now