由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Database版 - java sql help!
相关主题
A sql question急,SQL2005, 怎么查过去一小时里run过的所有query?
问个数据库问题Late afternoon 腦不好使
how to get the result in the middle of resultset?请教怎么来log duration of a MYSQL procedure?
Java SQL --> resultset!!oracle和XML
java database access problem!!!How to query a tree
SQL Server Update Query - non-unique valuea complex sql query, high hand help!!!
关于not closed cursor的请教如何完成这个sql?
[转载] Can anyone interpret this simple SQL?One sql question help!
相关话题的讨论汇总
话题: query话题: sql话题: select话题: destname话题: messages
进入Database版参与讨论
1 (共1页)
i*****t
发帖数: 220
1
I write this query:
String query = null;
query = "SELECT * from messages where " + "destname = '" + name + "'";
ResultSet rs = statement.executeQuery (query);
After running, the system always says: SQLException :No data found
But if I go to the database using SQL: SELECT * from messages where destname =
'clinton'; it works and finds data. What is wrong?
g**n
发帖数: 431
2
Check the value of name

【在 i*****t 的大作中提到】
: I write this query:
: String query = null;
: query = "SELECT * from messages where " + "destname = '" + name + "'";
: ResultSet rs = statement.executeQuery (query);
: After running, the system always says: SQLException :No data found
: But if I go to the database using SQL: SELECT * from messages where destname =
: 'clinton'; it works and finds data. What is wrong?

1 (共1页)
进入Database版参与讨论
相关主题
One sql question help!java database access problem!!!
pls help me in this Sql querySQL Server Update Query - non-unique value
ask for help with a simple query!!!关于not closed cursor的请教
[转载] 求教数据库的query optimization 工作的面试[转载] Can anyone interpret this simple SQL?
A sql question急,SQL2005, 怎么查过去一小时里run过的所有query?
问个数据库问题Late afternoon 腦不好使
how to get the result in the middle of resultset?请教怎么来log duration of a MYSQL procedure?
Java SQL --> resultset!!oracle和XML
相关话题的讨论汇总
话题: query话题: sql话题: select话题: destname话题: messages