You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Dan Zaitoun <da...@jajah.com> on 2014/12/31 15:11:15 UTC

Using the same parameter value

HI,
I wrote a script in jmeter that used the ${__UUID} in the first call of the script. I would like to use the same value in other calls of the iteration of the script.
But each iteration I need to create other GUID..
Currently for each call that I;m doing it create other value.
I tried to create user defined value, but the value doesn't changed in each iteration but stay the same of all the test.
Can Anyone help me here?
Thanks
Dan

[cid:image001.png@01D02514.66503310]Dan zaitoun ||dan@jajah.com<ma...@jajah.com>| 17 Hatidhar St., Raanana, 43665, Israel |  Mobile: +972-54-6880500 |


Re: Using the same parameter value

Posted by Flavio Cysne <fl...@gmail.com>.
Sorry, the correct expression is ${__javaScript(vars.put(myID,${__UUID}))}
Em 05/01/2015 13:36, "Flavio Cysne" <fl...@gmail.com> escreveu:

> You could also use the expression
> ${__javaScript(vars.put(${__UUID},myID))} and add ${myID} in other samplers
> refering the uuid value generated.
> Em 31/12/2014 14:40, "Aditya Dhage" <ad...@globallogic.com>
> escreveu:
>
>> Hi,
>> I've been through the same problem recently.
>>
>> User defined value are assigned only once at the start of the test plan.
>>
>> You can use pre processor called 'User Parameters' to generate unique
>> values per iteration. You can also assign it to a variable and use it
>> again.
>>
>> Regards,
>> Aditya Dhage
>>
>> On 31 Dec 2014 19:47, "Dan Zaitoun" <da...@jajah.com> wrote:
>>
>> >  HI,
>> >
>> > I wrote a script in jmeter that used the ${__UUID} in the first call of
>> > the script. I would like to use the same value in other calls of the
>> > iteration of the script.
>> >
>> > But each iteration I need to create other GUID..
>> >
>> > Currently for each call that I;m doing it create other value.
>> >
>> > I tried to create user defined value, but the value doesn’t changed in
>> > each iteration but stay the same of all the test.
>> >
>> > Can Anyone help me here?
>> >
>> > Thanks
>> >
>> > Dan
>> >
>> >
>> >
>> > *Dan zaitoun* *||*dan@jajah.com*| *17 Hatidhar St., Raanana, 43665,
>> > Israel *|*  Mobile: +972-54-6880500 *|*
>> >
>> >
>> >
>>
>

Re: Using the same parameter value

Posted by Flavio Cysne <fl...@gmail.com>.
You could also use the expression ${__javaScript(vars.put(${__UUID},myID))}
and add ${myID} in other samplers refering the uuid value generated.
Em 31/12/2014 14:40, "Aditya Dhage" <ad...@globallogic.com> escreveu:

> Hi,
> I've been through the same problem recently.
>
> User defined value are assigned only once at the start of the test plan.
>
> You can use pre processor called 'User Parameters' to generate unique
> values per iteration. You can also assign it to a variable and use it
> again.
>
> Regards,
> Aditya Dhage
>
> On 31 Dec 2014 19:47, "Dan Zaitoun" <da...@jajah.com> wrote:
>
> >  HI,
> >
> > I wrote a script in jmeter that used the ${__UUID} in the first call of
> > the script. I would like to use the same value in other calls of the
> > iteration of the script.
> >
> > But each iteration I need to create other GUID..
> >
> > Currently for each call that I;m doing it create other value.
> >
> > I tried to create user defined value, but the value doesn’t changed in
> > each iteration but stay the same of all the test.
> >
> > Can Anyone help me here?
> >
> > Thanks
> >
> > Dan
> >
> >
> >
> > *Dan zaitoun* *||*dan@jajah.com*| *17 Hatidhar St., Raanana, 43665,
> > Israel *|*  Mobile: +972-54-6880500 *|*
> >
> >
> >
>

Re: Using the same parameter value

Posted by Aditya Dhage <ad...@globallogic.com>.
Hi,
I've been through the same problem recently.

User defined value are assigned only once at the start of the test plan.

You can use pre processor called 'User Parameters' to generate unique
values per iteration. You can also assign it to a variable and use it again.

Regards,
Aditya Dhage

On 31 Dec 2014 19:47, "Dan Zaitoun" <da...@jajah.com> wrote:

>  HI,
>
> I wrote a script in jmeter that used the ${__UUID} in the first call of
> the script. I would like to use the same value in other calls of the
> iteration of the script.
>
> But each iteration I need to create other GUID..
>
> Currently for each call that I;m doing it create other value.
>
> I tried to create user defined value, but the value doesn’t changed in
> each iteration but stay the same of all the test.
>
> Can Anyone help me here?
>
> Thanks
>
> Dan
>
>
>
> *Dan zaitoun* *||*dan@jajah.com*| *17 Hatidhar St., Raanana, 43665,
> Israel *|*  Mobile: +972-54-6880500 *|*
>
>
>