... my $info = $query->param('info'); $info =~ s/\n/

/g; my $sql = sprintf "insert into test values(%s)", $dbh->quote($info); $dbh->do($sql) || die; ... #### Hello, This is a test. Bye Bye. #### test=> select * from test; stuff -----------------------------------------------

Bye Bye.a test. (1 row)