in reply to Perl Access Database

You could probably solve the problem by changing your assignment statements to give a value when the user input is not defined. e.g. $AC = $q->param('AC') || "NULL"; If the user doesn't input anything for that variable, then you'll get the string "NULL" instead of undef.