java.sql.SQLException: The SQL statement must not be null or empty.这个错误

今天发现了这个错误

java.sql.SQLException: The SQL statement must not be null or empty.

并且看了些网页:综合说下这个错误。

一般都是我这种原因:

在executeQuery之前,我System.out.printf 你的sql,原来是空串。

只要这样if 下就轻松解决了

posted @ 2013-07-20 17:19  程序员泥瓦匠  阅读(6634)  评论(0编辑  收藏  举报