Hello everyone. I have some confusion on passing variables.

I need to store variables from a form and then retrieve them later. What I have is three form that a user fills out and presses a next button to go to the next one. So the idea is to have the values from the text boxes stored and when the final form is finished retrieve all the variables for an SQL command.
Any ideas will be greatly appreciated.
Thanks,
Jesse