You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Xueling Shu <xs...@roadie.com> on 2015/07/15 22:16:01 UTC

How to run .sql file in JMeter

Hi there,

Is there a way to run .sql file in JMeter? The file contains a bunch of sql ops wrapped between BEGIN and COMMIT. 

Thanks,
Xueling


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org


Re: How to run .sql file in JMeter

Posted by Felix Schumacher <fe...@internetallee.de>.

Am 15. Juli 2015 22:16:01 MESZ, schrieb Xueling Shu <xs...@roadie.com>:
>Hi there,
>
>Is there a way to run .sql file in JMeter? The file contains a bunch of
>sql ops wrapped between BEGIN and COMMIT. 

Not out of the box, but you can combine two features to get there. 

There is a function called __FileToString which reads in a complete file and that can be put inside an evaluating string (${__FileToString (...)}), which can be placed in the jdbc sampler. 

See http://jmeter.apache.org/usermanual/functions.html#__FileToString for more infos. 

I haven't tested it, but am pretty sure it should work. 

Regards, 
Felix 

>
>Thanks,
>Xueling
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
>For additional commands, e-mail: user-help@jmeter.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org