You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by "Fabien D." <du...@hotmail.com> on 2008/09/17 12:05:23 UTC

Regular Expression with "="

Hi everybody,

I’m new French user of jmeter, and actually I have a problem with regular
expression.

My regular expression which I want to extract contains sometimes “=”. 

For example:
name="_txid" value="MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk="

In my regular expression extractor component in jmeter, I have done this:
name="_txid" value="(.+?)"

It returns this: 
MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D

So it changes “=” by “%3D”

How can I avoid this behaviour?

Thank you in advance for your help,
-- 
View this message in context: http://www.nabble.com/Regular-Expression-with-%22%3D%22-tp19528903p19528903.html
Sent from the JMeter - User mailing list archive at Nabble.com.


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


Re: Regular Expression with "="

Posted by "Fabien D." <du...@hotmail.com>.
Thank you for your help,

You were right, I reuses my value in an URL parameter, but this parameter is
not encoded. 
But for the moment, I don't see again this behaviour, and I don't know very
well the application that I have to test.

Wait and see :)


Andrey Beznogov wrote:
> 
> Hi,
> 
> I may be mistaken, but I think that Regular Expression Extractor does
> no such encoding.
> 
> "It returns this: MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D"
> probably means that you passed the found value to the HTTP Request
> sampler POST parameters, and then looked up the request parameters as
> they were sent, probably in View Results Tree listener. If that is the
> case, the encoding was done by the HTTP Request sampler - just uncheck
> the "Encode?' option for that line in HTTP Request parameters list to
> turn off the encoding.
> 
> Regards,
> Andrey
> 
> On Wed, Sep 17, 2008 at 2:05 PM, Fabien D. <du...@hotmail.com>
> wrote:
>>
>> Hi everybody,
>>
>> I'm new French user of jmeter, and actually I have a problem with regular
>> expression.
>>
>> My regular expression which I want to extract contains sometimes "=".
>>
>> For example:
>> name="_txid" value="MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk="
>>
>> In my regular expression extractor component in jmeter, I have done this:
>> name="_txid" value="(.+?)"
>>
>> It returns this:
>> MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D
>>
>> So it changes "=" by "%3D"
>>
>> How can I avoid this behaviour?
>>
>> Thank you in advance for your help,
>> --
>> View this message in context:
>> http://www.nabble.com/Regular-Expression-with-%22%3D%22-tp19528903p19528903.html
>> Sent from the JMeter - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>>
>>
> 
> 
> 
> -- 
> diem perdidi
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Regular-Expression-with-%22%3D%22-tp19528903p19529643.html
Sent from the JMeter - User mailing list archive at Nabble.com.


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


Re: Regular Expression with "="

Posted by sebb <se...@gmail.com>.
Andrey is not mistaken ...

The RE Extractor operates on the raw data as returned by the sampler.
You can confirm that by looking in the Tree View Listener response
pane.

It's not a URL, but you can use the techniques described here to fix
the value if required:

http://wiki.apache.org/jakarta-jmeter/EscapedURLs

But as Andrey points out: if you want to use the value later as a
parameter just tell JMeter that it is already escaped. Should work, if
not use the workround above.

On 17/09/2008, Andrey Beznogov <an...@googlemail.com> wrote:
> Hi,
>
>  I may be mistaken, but I think that Regular Expression Extractor does
>  no such encoding.
>
>
>  "It returns this: MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D"
>
> probably means that you passed the found value to the HTTP Request
>  sampler POST parameters, and then looked up the request parameters as
>  they were sent, probably in View Results Tree listener. If that is the
>  case, the encoding was done by the HTTP Request sampler - just uncheck
>  the "Encode?' option for that line in HTTP Request parameters list to
>  turn off the encoding.
>
>  Regards,
>  Andrey
>
>
>  On Wed, Sep 17, 2008 at 2:05 PM, Fabien D. <du...@hotmail.com> wrote:
>  >
>  > Hi everybody,
>  >
>  > I'm new French user of jmeter, and actually I have a problem with regular
>  > expression.
>  >
>  > My regular expression which I want to extract contains sometimes "=".
>  >
>  > For example:
>  > name="_txid" value="MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk="
>  >
>  > In my regular expression extractor component in jmeter, I have done this:
>  > name="_txid" value="(.+?)"
>  >
>  > It returns this:
>  > MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D
>  >
>  > So it changes "=" by "%3D"
>  >
>  > How can I avoid this behaviour?
>  >
>  > Thank you in advance for your help,
>  > --
>  > View this message in context: http://www.nabble.com/Regular-Expression-with-%22%3D%22-tp19528903p19528903.html
>  > Sent from the JMeter - User mailing list archive at Nabble.com.
>  >
>  >
>  > ---------------------------------------------------------------------
>  > To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  > For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>  >
>  >
>
>
>
>
> --
>  diem perdidi
>
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
>  For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>

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


Re: Regular Expression with "="

Posted by Andrey Beznogov <an...@googlemail.com>.
Hi,

I may be mistaken, but I think that Regular Expression Extractor does
no such encoding.

"It returns this: MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D"
probably means that you passed the found value to the HTTP Request
sampler POST parameters, and then looked up the request parameters as
they were sent, probably in View Results Tree listener. If that is the
case, the encoding was done by the HTTP Request sampler - just uncheck
the "Encode?' option for that line in HTTP Request parameters list to
turn off the encoding.

Regards,
Andrey

On Wed, Sep 17, 2008 at 2:05 PM, Fabien D. <du...@hotmail.com> wrote:
>
> Hi everybody,
>
> I'm new French user of jmeter, and actually I have a problem with regular
> expression.
>
> My regular expression which I want to extract contains sometimes "=".
>
> For example:
> name="_txid" value="MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk="
>
> In my regular expression extractor component in jmeter, I have done this:
> name="_txid" value="(.+?)"
>
> It returns this:
> MjI4Mzg4NTU3NDhkMGQyNmI2NGQzZTQuNDIyNzQ4OTk%3D
>
> So it changes "=" by "%3D"
>
> How can I avoid this behaviour?
>
> Thank you in advance for your help,
> --
> View this message in context: http://www.nabble.com/Regular-Expression-with-%22%3D%22-tp19528903p19528903.html
> Sent from the JMeter - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jmeter-user-help@jakarta.apache.org
>
>



-- 
diem perdidi

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