On 04/09/07, Renou, Stephane <[EMAIL PROTECTED]> wrote:
> Hello,
> I am trying to use Jmeter to stress test an SQL database.
>
> As I searched a little bit to set it up, it could be useful to add to
> the bottom of the manual page
> http://jakarta.apache.org/jmeter/usermanual/build-db-test-plan.html how
> to connect to a SQL server database.
>
> I am using MS JDBC driver:
> Driver class com.microsoft.sqlserver.jdbc.SQLServerDriver
> for Database URL: jdbc:sqlserver://host:port;DatabaseName=dbname
Thanks, I'll add that to the documentation.
> I also wanted to use NULL values for parameters but could not find a way
> to do so. Looking at the code it does not seem possible, do you agree?
Yes.
I suppose one could use a special text value for NULL - indeed "NULL"
would be fine for non-text fields such as numbers and dates, but that
is a valid text field.
Perhaps one could default to using something like "]NULL[", but allow
it to be overridden (e.g via a property) in case someone wanted to use
that in a text field.
> Also, it took me some time to identify a typo in the JDBC type, and it
> may be usefull to add some code to capture nullpointerexception when
> calling getJdbcType, something like:
>
> try {
> int targetSqlType = getJdbcType(argumentType);
> pstmt.setObject(i+1, argument, targetSqlType);
> } catch (NullPointerException e}
> log.warn("Invalid Type " + argumentType, e);
> throw e;
> }
Good point, I'll fix that.
> I did not get yet the environment to compile Jmeter, so could not
> validate the code, but this would provide a warning showing the exact
> entry that is failing.
>
> Lastly I could not find a way to use OUT parameters when using callable
> statement, is there any way?
I've not looked at that - I expect it would need some extra code to
handle these.
How would you expect to see these?
Should they be returned as text in the response?
> Stephane
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]