On 19/09/2008, Fabien D. <[EMAIL PROTECTED]> wrote:
>
> Hi everybody,
>
> I have a HTTP requet to test Web Service for saving data in ma database.
> I use RE to catch the id of the data, and save all of them, to reuse them
> for updatating test.
You can save the values of any variables in the JTL sample data output
file - just define the variable names in the JMeter property:
sample_variables=VAR1,VAR2,...
> To do this, I create a beanShel :
What sort of BeanShell?
And where is it placed?
> String value = vars.get("idCree");
> String value2 = vars.get("type_ressource");
>
> try{
> BufferedWriter out = new BufferedWriter(new
> FileWriter("D:/fabien/eng_clients tests/csvdata20.txt",true));
> out.write(value+ ";"+value2+"\n");
> out.close();
> } catch (IOException e) {}
>
> The problem is that the "idCree" is always the same, the first id of the
> data inserted.
>
> This is the file created :
>
> 64431;dysfonctionnementLocal
> 64431;dysfonctionnementLocal
> 64431;divers
> 64431;divers
> 64431;divers
> .......
> 64431;reclamation
> 64431;reclamation
>
> I don't know why I have this behavior, because "type_ressource" becomes from
> csv file and "idCree" RE.
>
> Thank you for your help.
>
> --
> View this message in context:
> http://www.nabble.com/BeanShel-and-RE--%3E-save-tp19572668p19572668.html
> Sent from the JMeter - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> 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]