469,915 Members | 2,599 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,915 developers. It's quick & easy.

Temporarirly storing web form data to be inserted into Database ?

I have a web application with two forms. After user enters data in first form
he is directed to the second form. After Filling the second form as he clicks
on save button, the data entered is stored in the database using a
Transaction Object, That inserts data, entered by user in both the forms, in
the database.

My problem is where shall i store the data entered by the user in the first
form when he is redirected to next form and till i perform the transaction?
--
Thank You.

Saket Mundra
Nov 19 '05 #1
6 1942
In a Session :

Session("TemporaryData") = DatatableContainingTemporaryData
"Saket Mundra" <Sa*********@discussions.microsoft.com> wrote in message
news:A1**********************************@microsof t.com...
I have a web application with two forms. After user enters data in first
form
he is directed to the second form. After Filling the second form as he
clicks
on save button, the data entered is stored in the database using a
Transaction Object, That inserts data, entered by user in both the forms,
in
the database.

My problem is where shall i store the data entered by the user in the
first
form when he is redirected to next form and till i perform the
transaction?
--
Thank You.

Saket Mundra

Nov 19 '05 #2
The question is can your users deal with the potential for the loss od data
from page 1 to page 2? If not, then store the data in the database inbetween
the pages, in a temp save table, perhaps. If they can deal with the possibility
of loss of data, then Session state is an acceptable place to store state
across pages.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have a web application with two forms. After user enters data in
first form he is directed to the second form. After Filling the second
form as he clicks on save button, the data entered is stored in the
database using a Transaction Object, That inserts data, entered by
user in both the forms, in the database.

My problem is where shall i store the data entered by the user in the
first form when he is redirected to next form and till i perform the
transaction?

Saket Mundra


Nov 19 '05 #3
Thank you for the replies.
I understand that the data can be stored in Session variables or temporary
tables.

However, say if i have more then 6 forms in which the user enters the data
one by one and after entering the data on last form he saves it. At this
point in time i am saving the data in the database through a transaction.

So, now the question arises is it advisable to create so many temporary
tables or Session variables for each form before the transaction takes place.

The most important point is the user cannot afford to lose data between forms.
Please Help.

Saket Mundra

"Brock Allen" wrote:
The question is can your users deal with the potential for the loss od data
from page 1 to page 2? If not, then store the data in the database inbetween
the pages, in a temp save table, perhaps. If they can deal with the possibility
of loss of data, then Session state is an acceptable place to store state
across pages.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I have a web application with two forms. After user enters data in
first form he is directed to the second form. After Filling the second
form as he clicks on save button, the data entered is stored in the
database using a Transaction Object, That inserts data, entered by
user in both the forms, in the database.

My problem is where shall i store the data entered by the user in the
first form when he is redirected to next form and till i perform the
transaction?

Saket Mundra


Nov 19 '05 #4
> The most important point is the user cannot afford to lose data
between forms. Please Help.


Then you've just answered it -- you must save it between forms. Then once
the user is done with all the forms, then move all the data to your "real"
tables within your transaction.

-Brock
DevelopMentor
http://staff.develop.com/ballen

Nov 19 '05 #5
Thanx again for your reply Brock.

I got your point and thuis is what I have been doing. Its just that i am
looking for something more comprehensive. And moreover, i want to get away
with writing all the code required to save the data in temporary tables and
then in real Database.

Also I am quite unsure about the memory this technique will consume, Is
there no other way to do so but to create temporary tables for each of the
forms.

Thank you.

Saket

"Brock Allen" wrote:
The most important point is the user cannot afford to lose data
between forms. Please Help.


Then you've just answered it -- you must save it between forms. Then once
the user is done with all the forms, then move all the data to your "real"
tables within your transaction.

-Brock
DevelopMentor
http://staff.develop.com/ballen

Nov 19 '05 #6
The tables idea is the most robust. It should take no extra storage doing
it this way as in your transaction you would move the data from the
temporary tables to the permanent tables, so no space lost.
"Saket Mundra" <Sa*********@discussions.microsoft.com> wrote in message
news:D0**********************************@microsof t.com...
Thanx again for your reply Brock.

I got your point and thuis is what I have been doing. Its just that i am
looking for something more comprehensive. And moreover, i want to get away
with writing all the code required to save the data in temporary tables
and
then in real Database.

Also I am quite unsure about the memory this technique will consume, Is
there no other way to do so but to create temporary tables for each of the
forms.

Thank you.

Saket

"Brock Allen" wrote:
> The most important point is the user cannot afford to lose data
> between forms. Please Help.


Then you've just answered it -- you must save it between forms. Then once
the user is done with all the forms, then move all the data to your
"real"
tables within your transaction.

-Brock
DevelopMentor
http://staff.develop.com/ballen

Nov 19 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by DarthMacgyver | last post: by
3 posts views Thread by josh.kuo | last post: by
reply views Thread by =?Utf-8?B?QkFUT04=?= | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.