in reply to not able to insert data in database using perl DBI
The error message is:
Undefined subroutine &main::execute called at ...
This originates from this line:
$sth = execute(...)
That's not how you should call the ->execute method of a statement handle. Use $sth->... as you do everywhere else.
In Section
Seekers of Perl Wisdom