Author: sebb
Date: Thu Oct 28 22:12:22 2010
New Revision: 1028518
URL: http://svn.apache.org/viewvc?rev=1028518&view=rev
Log:
Bug 50173 - JDBCSampler discards ResultSet from a PreparedStatement
Modified:
jakarta/jmeter/trunk/src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/sampler/JDBCSampler.java
jakarta/jmeter/trunk/xdocs/changes.xml
Modified:
jakarta/jmeter/trunk/src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/sampler/JDBCSampler.java
URL:
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/sampler/JDBCSampler.java?rev=1028518&r1=1028517&r2=1028518&view=diff
==============================================================================
---
jakarta/jmeter/trunk/src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/sampler/JDBCSampler.java
(original)
+++
jakarta/jmeter/trunk/src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/sampler/JDBCSampler.java
Thu Oct 28 22:12:22 2010
@@ -204,8 +204,8 @@ public class JDBCSampler extends Abstrac
} else if (PREPARED_SELECT.equals(_queryType)) {
PreparedStatement pstmt = getPreparedStatement(conn);
setArguments(pstmt);
- pstmt.executeQuery();
- String sb = resultSetsToString(pstmt,true,null);
+ boolean hasResultSet = pstmt.execute();
+ String sb = resultSetsToString(pstmt,hasResultSet,null);
res.setResponseData(sb.getBytes(ENCODING));
} else if (PREPARED_UPDATE.equals(_queryType)) {
PreparedStatement pstmt = getPreparedStatement(conn);
Modified: jakarta/jmeter/trunk/xdocs/changes.xml
URL:
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/xdocs/changes.xml?rev=1028518&r1=1028517&r2=1028518&view=diff
==============================================================================
--- jakarta/jmeter/trunk/xdocs/changes.xml (original)
+++ jakarta/jmeter/trunk/xdocs/changes.xml Thu Oct 28 22:12:22 2010
@@ -72,6 +72,7 @@ To override the default local language f
<h3>Other Samplers</h3>
<ul>
+<li>Bug 50173 - JDBCSampler discards ResultSet from a PreparedStatement</li>
</ul>
<h3>Controllers</h3>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]