in reply to DBI and the hell it has made my life...
Yes, the error is expected, and the behavior is correct. do() doesn't return a Statement Handle. Use prepare() instead