On Thu, Aug 11, 2011 at 3:43 PM, Nermin Caluk <ner...@atlantbh.com> wrote:
> Match No = -1 will match ALL occurrences > > Example: say your regex is <code>(.+?)</code> and Match no is -1. If there > are more than one occurrences of <code> this will match all of them, like > ${EXTRACTED_CODE_1}, ${EXTRACTED_CODE_2}, ${EXTRACTED_CODE_3} etc. If there > are 3 matches, than you will also get a variable like > ${EXTRACTED_CODE_matchnr} with the value of 3, which is useful if you want > to Loop through all of them. > > In the same example, if you would use Match no. = 2, this would match only > the 2nd occurrence. Match no = 0 would match a random item. > Has its advantages, like the regExVariable_matchNr, but it complicates things in the sense that you have to know what group to reference after - I think its still best practice to avoid getting all occurrences in most situations (because of memory, CPU), but its useful to know this is possible. Thanks all for solving this issue, last time I needed something like the OP needed, I had to use the XPath extractor instead. > > Hope this helps, > Nermin > > > > -----Original Message----- > From: Adrian Speteanu [mailto:asp.ad...@gmail.com] > Sent: 11. kolovoz 2011 14:29 > To: JMeter Users List > Subject: Re: Re: Saving the reply in Jmeter > > Why are you all using Match No.: -1 ? > > On Thu, Aug 11, 2011 at 2:48 PM, <rajivkumarnandv...@gmail.com> wrote: > > > :) lolz i alws be here in mail :) > > > > > > On , Oliver Lloyd <oliver_ll...@hotmail.com> wrote: > > > >> Thanks Raj, where would we be without you. > >> > > > > > > > > -- > >> > > > > View this message in context: http://jmeter.512774.n5.** > >> nabble.com/Saving-the-reply-**in-Jmeter-tp4687066p4689158.**html< > http://jmeter.512774.n5.nabble.com/Saving-the-reply-in-Jmeter-tp4687066p4689158.html > > > >> > > > > Sent from the JMeter - User mailing list archive at Nabble.com. > >> > > > > > > > > > ------------------------------**------------------------------**--------- > >> > > > > To unsubscribe, e-mail: jmeter-user-unsubscribe@**jakarta.apache.org< > jmeter-user-unsubscr...@jakarta.apache.org> > >> > > > > For additional commands, e-mail: jmeter-user-help@jakarta.**apache.org< > jmeter-user-h...@jakarta.apache.org> > >> > > > > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: jmeter-user-unsubscr...@jakarta.apache.org > For additional commands, e-mail: jmeter-user-h...@jakarta.apache.org > >