I can't use Match No = 0 because I could get a different link for each of the three Regular Expression Extractors. I need each part from the same link.
This would be fairly simple if I understood how to assign a variable directly. For example, suppose I have: Var_1_g=3 Var_1_g0=href="pagerequest.aspx?a=7000&b=104&c=12047 Var_1_g1=7000 Var_1_g2=104 Var_1_g3=12047 What I would like to end up with is three output variables: A = Var_1_g1 = 7000 B = Var_1_g2 = 104 C = Var_1_g3 = 12047 I can't figure out from the documentation how to set the value of a variable outside of a Regular Expression Extractor or a Random Variable. Steve -----Original Message----- From: sebb [mailto:seb...@gmail.com] Sent: Friday, August 28, 2009 12:02 PM To: JMeter Users List Subject: Re: Help With Passing Multiple Variables From a Regular Expression Extractor Or just use Match No = 0 and JMeter will choose a match at random. On 28/08/2009, Deepak Shetty <shet...@gmail.com> wrote: > Hi > You'd probably need to check the scoping rules for Random variable config > element. I think you've created everything as children of the HTTP request > right? > > Depending on how easy difficult it is to extract the values i would try > Option 1 > a. Each Parameter is extracted separately (so in your case you would have 4 > Regex extractors , 1 per parameter) > b. Use __Random and __V to randomise the index and pick out the value > http://jakarta.apache.org/jmeter/usermanual/functions.html (I think this is > what you were trying) > > Option 2 > If its easier to extract all parameters for 1 type (e.g. they are the query > string of some url). In this case you only have 1 Regex (each result has all > parameters and you have multiple results that you want to randomise) , Use a > beanshell script or function to parse the parameters out and set them into > variables, and use random again... > > regards > deepak > > > On Fri, Aug 28, 2009 at 6:36 AM, Steve Eckhart > <steve.eckh...@wausaufs.com>wrote: > > > > I am having difficulty understanding how to pull multiple values from a > > Regular Expression Extractor and pass them along in my script. > > > > Basically, here's what I'm trying to accomplish: > > > > 1. Submit a form which will return 0 or more links to other pages. Each > > link has four parameters which I need to pull out for later processing. > > > > 2. Randomly select one of the links. > > > > 3. Put the four parameters into four variables for use by another > > Controller. > > > > Here's what I tried (which doesn't seem to work): > > > > * HTTP Request > > > > o Regular Expression Extractor-Var (all of the Var on the page will be > > the same value) > > > > o Random Variable from 1 to ${Var_matchNr} called Sample > > > > o Regular Expression Extractor with Match No. set to ${Sample} for each > > of the other parameters. > > > > When I run this with a Debug Sampler, Sample is not getting set to > > anything. > > > > Is there a way to just set a variable to a value during processing? Is > > there a better way to do what I'm doing? > > > > Thanks, > > > > Steve Eckhart > > Business Analyst/Project Manager > > > > WAUSAU Financial Systems > > 14010 FNB PKWY STE500 > > Omaha, NE 68154-5206 > > Main: (402) 431-8810 > > Direct line: (402) 715-9382 > > Cellular: (402) 510-5387 > > Email: steve.eckh...@wausaufs.com<blocked::mailto: > > steve.eckh...@wausaufs.com> > > > > Enterprise Payment Solutions. > > CONFIDENTIALITY NOTICE: This electronic transmission (including files > > attached hereto) is intended only for the use of the individual or entity > > named above. If the reader of this message is not the intended recipient, > > you are hereby notified that any disclosure, dissemination, copying, > > distribution or taking of any action in reliance on the contents of this > > confidential information is strictly prohibited. If you have received this > > communication in error, please destroy it and immediately notify us by > > return email. Thank you. > > > --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscr...@jakarta.apache.org For additional commands, e-mail: 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