As others have suggested, life will be better for you when you use an array for field names, a hash for field values (keyed by the names in the array), placeholders in your sql statements, and loops to keep everything compact and non-repetitive.
Once you are enjoying the beauty of all that, you'll really want to get acquainted with a cross-platform GUI library, especially for this sort of application. It's just much nicer for a user to fill in fields in a form, and have the ability to review all the values for a record (and maybe fix one or two of them) before submitting the complete record to the database with the click of a button. Take your pick of Tk, Wx, Qt or Gtk. Even Curses would be better than your current approach.
The worst torture I can imagine for someone doing keyboard entry to a database is having to use the OP's style of irreversible, "one-field-at-a-time" sequential dialog. The likelihood of making a mistake that requires a complete start-over is so high that actually completing a single record entry becomes a daunting and maddening task.
You can find a lot of self-contained sample GUI programs here at the Monastery that use most of the libraries cited above; also, a lot of the libraries come with very nice demo programs that show you how things work, and how the code is written to do those things.