if ($seq) # if existing call {set update display vars and sql_code} else {set insert display vars and sql_code}