From jmeter-user-return-5367-apmail-jakarta-jmeter-user-archive=jakarta.apache.org@jakarta.apache.org Fri Jul 23 10:42:36 2004 Return-Path: Delivered-To: apmail-jakarta-jmeter-user-archive@www.apache.org Received: (qmail 35121 invoked from network); 23 Jul 2004 10:42:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 23 Jul 2004 10:42:36 -0000 Received: (qmail 16472 invoked by uid 500); 23 Jul 2004 10:42:32 -0000 Delivered-To: apmail-jakarta-jmeter-user-archive@jakarta.apache.org Received: (qmail 16441 invoked by uid 500); 23 Jul 2004 10:42:32 -0000 Mailing-List: contact jmeter-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "JMeter Users List" Reply-To: "JMeter Users List" Delivered-To: mailing list jmeter-user@jakarta.apache.org Received: (qmail 16428 invoked by uid 99); 23 Jul 2004 10:42:32 -0000 X-ASF-Spam-Status: No, hits=0.6 required=10.0 tests=NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [213.61.162.210] (HELO kingler.idg.de) (213.61.162.210) by apache.org (qpsmtpd/0.27.1) with SMTP; Fri, 23 Jul 2004 03:42:28 -0700 Subject: Re: Re: Re: Can we use USER variable in Regular expression.'Viren geprueft!' To: "JMeter Users List" X-Mailer: Lotus Notes Release 5.0.11 July 24, 2002 Message-ID: From: Frank_Lindner@idg.de Date: Fri, 23 Jul 2004 12:36:55 +0100 X-MIMETrack: Serialize by Router on KLNW13/PARION-COM/DE(Release 6.5.1|January 28, 2004) at 23.07.2004 12:42:56 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Hi, my pleasure.. :) Well think we found kinda Bug, did we? Hope it gets or is already fixed. Best regards Frank |---------+----------------------------> | | shambu pujar | | | | | | | | | 23.07.2004 11:24 | | | Bitte antworten | | | an "JMeter Users | | | List" | | | | |---------+----------------------------> >------------------------------------------------------------------------------------------------------------------------------| | | | An: JMeter Users List | | Kopie: | | Thema: Re: Re: Can we use USER variable in Regular expression.'Viren geprueft!' | >------------------------------------------------------------------------------------------------------------------------------| hi Frank from the regular expression u have used one thing i came to know that if u put ur parameter at starting or at last ,value gets substituted. I tried with below expression and it worked for me ${RepName}','(\d+)'\) So it is that, the parameter should either be first ,as in my case or last as in frank's reg expression ,of the pattern u want to match , then the expression works.Jmeter seems to be not substituting if parameter is middle.Is this taken care of in Jmeter 2.0??? Frank thanks for your inputs! regards shambu Frank_Lindner@idg.de wrote: I can only say it worked for me. I used a .CSV file with numbers and used the 'User Parameter'-Controler to read them 1by1 ${__CSVRead(user.txt,0)}${__CSVRead(user.txt,next)}. Then I used a RegExtractor with a realy anoying RegEx: name="Selektion" value="(\d+)">\W\W\W\W\Wnowrap>\W\W+width="100%" height="100%">\W\Wclass="Attribut.">\W${AntragsNr} You see the last ist my number and I read the value. I'm using JMeter 1.9 so it works in this version. I tried to do a RegEx with a variable that I RegEx'ed in the same request but this didn't work the way I planned. Regards Frank |---------+----------------------------> | | shambu pujar | | | | | com> | | | | | | 23.07.2004 05:16 | | | Bitte antworten | | | an "JMeter Users | | | List" | | | | |---------+----------------------------> >------------------------------------------------------------------------------------------------------------------------------| | | | An: JMeter Users List | | Kopie: | | Thema: Re: Can we use USER variable in Regular expression.'Viren geprueft!' | >------------------------------------------------------------------------------------------------------------------------------| Frank_Lindner@idg.de wrote: Hi Exactly! I wanted to search with given or parametised name. setReport\('(\S+)','(\d+)'\) does not work for me as its give more than one matches and i would not able extract the same value that the thread earlier had been using it. But the expression setReport\('${RepName}','(\d+)'\) which searches for parameter RepName(what i wanted to happen ) is not working.It gives default value failed. Is it really that we can search for parameter or search using parameter in regular expression?? Regards Shambu Hi, try this Expression: setReport\('(\S+)','(\d+)'\) $1$ should give you the name while $2$ should give you the number. If you want to search with a given (parameterized) name you can put the variable in there setReport\('${RepName}','(\d+)'\) Hope it helps. Sidenote: For testing regular expressions I use this little WinProg http://weitz.de/regex-coach/ Maybe you want give it a try. Best Regards Frank |---------+----------------------------> | | shambu pujar | | | | | com> | | | | | | 22.07.2004 07:57 | | | Bitte antworten | | | an "JMeter Users | | | List" | | | | |---------+----------------------------> >------------------------------------------------------------------------------------------------------------------------------| | | | An: jmeter-user@jakarta.apache.org | | Kopie: | | Thema: Can we use USER variable in Regular expression.'Viren geprueft!' | >------------------------------------------------------------------------------------------------------------------------------| Hi, Here i m extratcing a value which represents ID . Snippet from which i am extracting is below onClick="setReport('study01','29')">class="navLinkSmall">study01 The value i am extracting is in Bold.It is number "29". and the "study01" coresponding text.. "study01" is from a parameter .So for second user it will be "study02" and Html response for second user will be something like "setReport('study02','30')">study01 since the value "study01" is from parameter RepName can i substitute this parameter into regular expression???? if i can what's is syntax??? and i hv used following regular expression and it is not working. setReport\(\'${RepName}\'\,\'(.*?)\'\) plz help me regards shambu --------------------------------- Do you Yahoo!? Vote for the stars of Yahoo!'s next ad campaign! --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org --------------------------------- Do you Yahoo!? Yahoo! Mail Address AutoComplete - You start. We finish. --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org --------------------------------- Do you Yahoo!? Vote for the stars of Yahoo!'s next ad campaign! --------------------------------------------------------------------- To unsubscribe, e-mail: jmeter-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: jmeter-user-help@jakarta.apache.org