You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Modha Khammammettu <MK...@calcas.com> on 2007/11/14 05:25:25 UTC

Regular Expression -- Help

Hi All

I am trying for

Reference Name: VehicleNumber
RE: invokeEvent('5_290_act', true)" class="button">Add</button>
Template: $1$
Match No: 1

I want the ReferenceName to have 5_290_act
I tried a few combinations and when I try to print I do not get what I
am looking for. Can some one please help.

Thanks
Modha/-

Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Thanks
> This works fine when I tried it in ORO demo.
> But when I tried the same thing in Jmeter script and print it as Java
> Request I get it as
>
> VehicleNumber: {${VehicleNumber} as result.

Not possible if you really used

VehicleNumber: ${VehicleNumber}

as the Java Request label.

Are you sure you spelt the label correctly?

> All other variables print just fine.
>
> I have the java request defined as follows

This is not a Java Request ...

> Reference Name: VehicleNumber
> RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> Template: 1$1
> Match No : 1

Set the default value so you can tell if the RE matched or not.
The RE does not set the variable at all if it did not match.

> When I am printing using "Java Request" I set the label as
> VehicleNumber: ${VehicleNumber}
>
>
> When I run my test the output is
> VehicleNumber: ${VehicleNumber}
>
> I expected
> VehicleNumber: 5_290_act
>
> I saw the page content in view result tree, it has the string
> invokeEvent('5_290_act', true)" class="button">Add</button>
>
> It is just happening with this particular variable.
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 5:53 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Hi All
> >
> > I am trying for
> >
> > Reference Name: VehicleNumber
> > RE: invokeEvent('5_290_act', true)" class="button">Add</button>
>
> If what you have labelled RE is the source you want to match against,
> then try
>
> invokeEvent\('([^']+)', true\)" class="button">Add</button>
>
> > Template: $1$
> > Match No: 1
> >
> > I want the ReferenceName to have 5_290_act
> >
> > I tried a few combinations and when I try to print I do not get what I
>
> > am looking for. Can some one please help.
>
> Have you tried the ORO demo?
>
> http://jakarta.apache.org/oro/demo.html
>
> > Thanks
> > Modha/-
> >
>
> ---------------------------------------------------------------------
> 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
>
>

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


Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Thanks
> I put it as $1$ only.
>
> When I put a default value as descr
> I get VehicleNumber: descr

That means the RE ran but did not find a match.

It also confirms that the variable reference was correctly spelt.

> -----Original Message-----
> From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> Sent: Wednesday, November 14, 2007 9:00 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> Modha Khammammettu wrote:
> > Thanks
> > This works fine when I tried it in ORO demo.
> > But when I tried the same thing in Jmeter script and print it as Java
> > Request I get it as
> >
> > VehicleNumber: {${VehicleNumber} as result.
> > All other variables print just fine.
> >
> > I have the java request defined as follows
> >
> > Reference Name: VehicleNumber
> > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > Template: 1$1
>
> ^ You had this right in your previous post - it should be: $1$
>
> > Match No : 1
> >
> > When I am printing using "Java Request" I set the label as
> > VehicleNumber: ${VehicleNumber}
> >
> >
> > When I run my test the output is
> > VehicleNumber: ${VehicleNumber}
> >
> > I expected
> > VehicleNumber: 5_290_act
> >
> > I saw the page content in view result tree, it has the string
> > invokeEvent('5_290_act', true)" class="button">Add</button>
> >
> > It is just happening with this particular variable.
> >
>
>
>
> --
> Ronan Klyne
> Business Collaborator Developer
> Tel: +44 (0)870 163 2555
> ronan.klyne@groupbc.com
> www.groupbc.com
>
> ---------------------------------------------------------------------
> 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
>
>

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


RE: Regular Expression -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Thanks

Finally got around the problem.
I deleted the node and recreated the node (RE Node) and things were
fine.

Somehow I think I node was corrupted. 

-----Original Message-----
From: Eric.Robinson@Schange.com [mailto:Eric.Robinson@Schange.com] 
Sent: Wednesday, November 14, 2007 1:02 PM
To: JMeter Users List
Subject: RE: Regular Expression -- Help

the label should be only ${VehicleNumber}

maybe an example would help:
I created a simple test plan:
Thread Group
-HTTP request (to www.yahoo.com)
    -Regular Expression Extractor
        -Response field to check: body
        -Reference name: href
        -Regular expression: href="(.+)"
        -Template: $1$
        -Match No.: 1
        -Default Value:
-Java Request ${href}
-Aggregate Report
-View Results Tree

in the aggregate report, the ${href} becomes the 1st href found in the
response data.  change Match No. to 2 and you'll see the 2nd.
jmx begin:
<?xml version="1.0" encoding="UTF-8"?>
<jmeterTestPlan version="1.2" properties="1.8">
  <hashTree>
    <TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="Test
Plan" enabled="true">
      <stringProp name="TestPlan.comments"></stringProp>
      <boolProp name="TestPlan.functional_mode">false</boolProp>
      <boolProp name="TestPlan.serialize_threadgroups">false</boolProp>
      <elementProp name="TestPlan.user_defined_variables" elementType="
Arguments" guiclass="ArgumentsPanel" testclass="Arguments"
testname="User Defined Variables" enabled="true">
        <collectionProp name="Arguments.arguments"/>
      </elementProp>
      <stringProp name="TestPlan.user_define_classpath"></stringProp>
    </TestPlan>
    <hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" 
testname="Thread Group" enabled="true">
        <elementProp name="ThreadGroup.main_controller" elementType="
LoopController" guiclass="LoopControlPanel" testclass="LoopController" 
testname="Loop Controller" enabled="true">
          <boolProp
name="LoopController.continue_forever">false</boolProp
>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <longProp name="ThreadGroup.start_time">1195069038000</longProp>
        <longProp name="ThreadGroup.end_time">1195069038000</longProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.on_sample_error">continue</
stringProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </ThreadGroup>
      <hashTree>
        <HTTPSampler guiclass="HttpTestSampleGui"
testclass="HTTPSampler" 
testname="HTTP Request" enabled="true">
          <elementProp name="HTTPsampler.Arguments"
elementType="Arguments " guiclass="HTTPArgumentsPanel"
testclass="Arguments" testname="User Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <stringProp
name="HTTPSampler.domain">www.yahoo.com</stringProp>
          <stringProp name="HTTPSampler.port"></stringProp>
          <stringProp name="HTTPSampler.protocol"></stringProp>
          <stringProp name="HTTPSampler.method">GET</stringProp>
          <stringProp name="HTTPSampler.contentEncoding"></stringProp>
          <stringProp name="HTTPSampler.path">/</stringProp>
          <boolProp name="HTTPSampler.follow_redirects">false</boolProp>
          <boolProp name="HTTPSampler.auto_redirects">true</boolProp>
          <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
          <boolProp
name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
          <stringProp name="HTTPSampler.mimetype"></stringProp>
          <stringProp name="HTTPSampler.FILE_NAME"></stringProp>
          <stringProp name="HTTPSampler.FILE_FIELD"></stringProp>
          <stringProp name="HTTPSampler.monitor">false</stringProp>
          <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
        </HTTPSampler>
        <hashTree>
          <RegexExtractor guiclass="RegexExtractorGui" testclass="
RegexExtractor" testname="Regular Expression Extractor" enabled="true">
            <stringProp
name="RegexExtractor.useHeaders">false</stringProp
>
            <stringProp name="RegexExtractor.refname">href</stringProp>
            <stringProp
name="RegexExtractor.regex">href=&quot;(.+)&quot;
</stringProp>
            <stringProp name="RegexExtractor.template">$1$</stringProp>
            <stringProp name="RegexExtractor.default"></stringProp>
            <stringProp
name="RegexExtractor.match_number">1</stringProp>
          </RegexExtractor>
          <hashTree/>
        </hashTree>
        <JavaSampler guiclass="JavaTestSamplerGui"
testclass="JavaSampler" 
testname="href: ${href}" enabled="true">
          <elementProp name="arguments" elementType="Arguments"
guiclass="
ArgumentsPanel" testclass="Arguments" enabled="true">
            <collectionProp name="Arguments.arguments">
              <elementProp name="Sleep_Time" elementType="Argument">
                <stringProp name="Argument.name">Sleep_Time</stringProp>
                <stringProp name="Argument.value">0</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Sleep_Mask" elementType="Argument">
                <stringProp name="Argument.name">Sleep_Mask</stringProp>
                <stringProp name="Argument.value">0xFF</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Label" elementType="Argument">
                <stringProp name="Argument.name">Label</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResponseCode" elementType="Argument">
                <stringProp
name="Argument.name">ResponseCode</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResponseMessage"
elementType="Argument">
                <stringProp name="Argument.name">ResponseMessage</
stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Status" elementType="Argument">
                <stringProp name="Argument.name">Status</stringProp>
                <stringProp name="Argument.value">OK</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="SamplerData" elementType="Argument">
                <stringProp
name="Argument.name">SamplerData</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResultData" elementType="Argument">
                <stringProp name="Argument.name">ResultData</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <stringProp name="classname">
org.apache.jmeter.protocol.java.test.JavaTest</stringProp>
        </JavaSampler>
        <hashTree/>
        <ResultCollector guiclass="StatVisualizer" testclass="
ResultCollector" testname="Aggregate Report" enabled="true">
          <boolProp
name="ResultCollector.error_logging">false</boolProp>
          <objProp>
            <value class="SampleSaveConfiguration">
              <time>true</time>
              <latency>true</latency>
              <timestamp>true</timestamp>
              <success>true</success>
              <label>true</label>
              <code>true</code>
              <message>true</message>
              <threadName>true</threadName>
              <dataType>true</dataType>
              <encoding>false</encoding>
              <assertions>true</assertions>
              <subresults>true</subresults>
              <responseData>false</responseData>
              <samplerData>false</samplerData>
              <xml>true</xml>
              <fieldNames>false</fieldNames>
              <responseHeaders>false</responseHeaders>
              <requestHeaders>false</requestHeaders>
              <responseDataOnError>false</responseDataOnError>
              <saveAssertionResultsFailureMessage>false</
saveAssertionResultsFailureMessage>
              <assertionsResultsToSave>0</assertionsResultsToSave>
              <bytes>true</bytes>
            </value>
            <name>saveConfig</name>
          </objProp>
          <stringProp name="filename"></stringProp>
        </ResultCollector>
        <hashTree/>
        <ResultCollector guiclass="ViewResultsFullVisualizer"
testclass="
ResultCollector" testname="View Results Tree" enabled="true">
          <boolProp
name="ResultCollector.error_logging">false</boolProp>
          <objProp>
            <value class="SampleSaveConfiguration">
              <time>true</time>
              <latency>true</latency>
              <timestamp>true</timestamp>
              <success>true</success>
              <label>true</label>
              <code>true</code>
              <message>true</message>
              <threadName>true</threadName>
              <dataType>true</dataType>
              <encoding>false</encoding>
              <assertions>true</assertions>
              <subresults>true</subresults>
              <responseData>false</responseData>
              <samplerData>false</samplerData>
              <xml>true</xml>
              <fieldNames>false</fieldNames>
              <responseHeaders>false</responseHeaders>
              <requestHeaders>false</requestHeaders>
              <responseDataOnError>false</responseDataOnError>
              <saveAssertionResultsFailureMessage>false</
saveAssertionResultsFailureMessage>
              <assertionsResultsToSave>0</assertionsResultsToSave>
              <bytes>true</bytes>
            </value>
            <name>saveConfig</name>
          </objProp>
          <stringProp name="filename"></stringProp>
        </ResultCollector>
        <hashTree/>
      </hashTree>
    </hashTree>
  </hashTree>
</jmeterTestPlan>

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


RE: Regular Expression -- Help

Posted by Er...@Schange.com.
the label should be only ${VehicleNumber}

maybe an example would help:
I created a simple test plan:
Thread Group
-HTTP request (to www.yahoo.com)
    -Regular Expression Extractor
        -Response field to check: body
        -Reference name: href
        -Regular expression: href="(.+)"
        -Template: $1$
        -Match No.: 1
        -Default Value:
-Java Request ${href}
-Aggregate Report
-View Results Tree

in the aggregate report, the ${href} becomes the 1st href found in the 
response data.  change Match No. to 2 and you'll see the 2nd.
jmx begin:
<?xml version="1.0" encoding="UTF-8"?>
<jmeterTestPlan version="1.2" properties="1.8">
  <hashTree>
    <TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="Test 
Plan" enabled="true">
      <stringProp name="TestPlan.comments"></stringProp>
      <boolProp name="TestPlan.functional_mode">false</boolProp>
      <boolProp name="TestPlan.serialize_threadgroups">false</boolProp>
      <elementProp name="TestPlan.user_defined_variables" elementType="
Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="User 
Defined Variables" enabled="true">
        <collectionProp name="Arguments.arguments"/>
      </elementProp>
      <stringProp name="TestPlan.user_define_classpath"></stringProp>
    </TestPlan>
    <hashTree>
      <ThreadGroup guiclass="ThreadGroupGui" testclass="ThreadGroup" 
testname="Thread Group" enabled="true">
        <elementProp name="ThreadGroup.main_controller" elementType="
LoopController" guiclass="LoopControlPanel" testclass="LoopController" 
testname="Loop Controller" enabled="true">
          <boolProp name="LoopController.continue_forever">false</boolProp
>
          <stringProp name="LoopController.loops">1</stringProp>
        </elementProp>
        <stringProp name="ThreadGroup.num_threads">1</stringProp>
        <stringProp name="ThreadGroup.ramp_time">1</stringProp>
        <longProp name="ThreadGroup.start_time">1195069038000</longProp>
        <longProp name="ThreadGroup.end_time">1195069038000</longProp>
        <boolProp name="ThreadGroup.scheduler">false</boolProp>
        <stringProp name="ThreadGroup.on_sample_error">continue</
stringProp>
        <stringProp name="ThreadGroup.duration"></stringProp>
        <stringProp name="ThreadGroup.delay"></stringProp>
      </ThreadGroup>
      <hashTree>
        <HTTPSampler guiclass="HttpTestSampleGui" testclass="HTTPSampler" 
testname="HTTP Request" enabled="true">
          <elementProp name="HTTPsampler.Arguments" elementType="Arguments
" guiclass="HTTPArgumentsPanel" testclass="Arguments" testname="User 
Defined Variables" enabled="true">
            <collectionProp name="Arguments.arguments"/>
          </elementProp>
          <stringProp name="HTTPSampler.domain">www.yahoo.com</stringProp>
          <stringProp name="HTTPSampler.port"></stringProp>
          <stringProp name="HTTPSampler.protocol"></stringProp>
          <stringProp name="HTTPSampler.method">GET</stringProp>
          <stringProp name="HTTPSampler.contentEncoding"></stringProp>
          <stringProp name="HTTPSampler.path">/</stringProp>
          <boolProp name="HTTPSampler.follow_redirects">false</boolProp>
          <boolProp name="HTTPSampler.auto_redirects">true</boolProp>
          <boolProp name="HTTPSampler.use_keepalive">true</boolProp>
          <boolProp name="HTTPSampler.DO_MULTIPART_POST">false</boolProp>
          <stringProp name="HTTPSampler.mimetype"></stringProp>
          <stringProp name="HTTPSampler.FILE_NAME"></stringProp>
          <stringProp name="HTTPSampler.FILE_FIELD"></stringProp>
          <stringProp name="HTTPSampler.monitor">false</stringProp>
          <stringProp name="HTTPSampler.embedded_url_re"></stringProp>
        </HTTPSampler>
        <hashTree>
          <RegexExtractor guiclass="RegexExtractorGui" testclass="
RegexExtractor" testname="Regular Expression Extractor" enabled="true">
            <stringProp name="RegexExtractor.useHeaders">false</stringProp
>
            <stringProp name="RegexExtractor.refname">href</stringProp>
            <stringProp name="RegexExtractor.regex">href=&quot;(.+)&quot;
</stringProp>
            <stringProp name="RegexExtractor.template">$1$</stringProp>
            <stringProp name="RegexExtractor.default"></stringProp>
            <stringProp name="RegexExtractor.match_number">1</stringProp>
          </RegexExtractor>
          <hashTree/>
        </hashTree>
        <JavaSampler guiclass="JavaTestSamplerGui" testclass="JavaSampler" 
testname="href: ${href}" enabled="true">
          <elementProp name="arguments" elementType="Arguments" guiclass="
ArgumentsPanel" testclass="Arguments" enabled="true">
            <collectionProp name="Arguments.arguments">
              <elementProp name="Sleep_Time" elementType="Argument">
                <stringProp name="Argument.name">Sleep_Time</stringProp>
                <stringProp name="Argument.value">0</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Sleep_Mask" elementType="Argument">
                <stringProp name="Argument.name">Sleep_Mask</stringProp>
                <stringProp name="Argument.value">0xFF</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Label" elementType="Argument">
                <stringProp name="Argument.name">Label</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResponseCode" elementType="Argument">
                <stringProp name="Argument.name">ResponseCode</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResponseMessage" elementType="Argument">
                <stringProp name="Argument.name">ResponseMessage</
stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="Status" elementType="Argument">
                <stringProp name="Argument.name">Status</stringProp>
                <stringProp name="Argument.value">OK</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="SamplerData" elementType="Argument">
                <stringProp name="Argument.name">SamplerData</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
              <elementProp name="ResultData" elementType="Argument">
                <stringProp name="Argument.name">ResultData</stringProp>
                <stringProp name="Argument.value"></stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
              </elementProp>
            </collectionProp>
          </elementProp>
          <stringProp name="classname">
org.apache.jmeter.protocol.java.test.JavaTest</stringProp>
        </JavaSampler>
        <hashTree/>
        <ResultCollector guiclass="StatVisualizer" testclass="
ResultCollector" testname="Aggregate Report" enabled="true">
          <boolProp name="ResultCollector.error_logging">false</boolProp>
          <objProp>
            <value class="SampleSaveConfiguration">
              <time>true</time>
              <latency>true</latency>
              <timestamp>true</timestamp>
              <success>true</success>
              <label>true</label>
              <code>true</code>
              <message>true</message>
              <threadName>true</threadName>
              <dataType>true</dataType>
              <encoding>false</encoding>
              <assertions>true</assertions>
              <subresults>true</subresults>
              <responseData>false</responseData>
              <samplerData>false</samplerData>
              <xml>true</xml>
              <fieldNames>false</fieldNames>
              <responseHeaders>false</responseHeaders>
              <requestHeaders>false</requestHeaders>
              <responseDataOnError>false</responseDataOnError>
              <saveAssertionResultsFailureMessage>false</
saveAssertionResultsFailureMessage>
              <assertionsResultsToSave>0</assertionsResultsToSave>
              <bytes>true</bytes>
            </value>
            <name>saveConfig</name>
          </objProp>
          <stringProp name="filename"></stringProp>
        </ResultCollector>
        <hashTree/>
        <ResultCollector guiclass="ViewResultsFullVisualizer" testclass="
ResultCollector" testname="View Results Tree" enabled="true">
          <boolProp name="ResultCollector.error_logging">false</boolProp>
          <objProp>
            <value class="SampleSaveConfiguration">
              <time>true</time>
              <latency>true</latency>
              <timestamp>true</timestamp>
              <success>true</success>
              <label>true</label>
              <code>true</code>
              <message>true</message>
              <threadName>true</threadName>
              <dataType>true</dataType>
              <encoding>false</encoding>
              <assertions>true</assertions>
              <subresults>true</subresults>
              <responseData>false</responseData>
              <samplerData>false</samplerData>
              <xml>true</xml>
              <fieldNames>false</fieldNames>
              <responseHeaders>false</responseHeaders>
              <requestHeaders>false</requestHeaders>
              <responseDataOnError>false</responseDataOnError>
              <saveAssertionResultsFailureMessage>false</
saveAssertionResultsFailureMessage>
              <assertionsResultsToSave>0</assertionsResultsToSave>
              <bytes>true</bytes>
            </value>
            <name>saveConfig</name>
          </objProp>
          <stringProp name="filename"></stringProp>
        </ResultCollector>
        <hashTree/>
      </hashTree>
    </hashTree>
  </hashTree>
</jmeterTestPlan>

RE: Regular Expression -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Reference Name: VehicleNumber
RE: invokeEvent\('(.*?)', true\)" class="button">Add</button>
Template: $1$
Match No: 1
Default Value : descr

The label is set to VehicleNumber: ${VehicleNumber_1_g1}
Status : FAIL

-----Original Message-----
From: Modha Khammammettu [mailto:MKhammammettu@calcas.com] 
Sent: Wednesday, November 14, 2007 12:24 PM
To: JMeter Users List
Subject: RE: Regular Expression -- Help

I always have match no set to 1

Reference Name: VehicleNumber
RE: invokeEvent\('(.*?)', true\)" class="button">Add</button>
Template: $1$
Match No: 1
Default Value : descr

The label is set to VehicleNumber: ${VehicleNumber_1_g1 Status : FAIL


-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 12:19 PM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

If you want to match a particular instance of a pattern, then use the
Match No - as described previously.

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Thanks sebb for your patience.
>
> I tried all possible combinations I can think of like..
>
> VehicleNumber: ${VehicleNumber_1_g1}
> VehicleNumber: ${VehicleNumber_1_g0}
> VehicleNumber: ${VehicleNumber_1}
> Etc
>
> It prints as it is like ${VehicleNumber_1_g1}, ${VehicleNumber_1_g0} 
> etc instead of 5_290_act
>
> Lack of samples in the Jmeter page is making particularly hard for
me...
>
> Can you please tell me where I went wrong?
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 11:11 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Ok I know (?) the problem
> >
> > There are 5 matches to the regular expression ( when I put the whole

> > page as input to ORO)
> >
> > ===================================================================
> > Compiling regular expression.
> >
> > Searching
> >
> > Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_290_act
> > Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_299_act
> > Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_306_act
> > Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_314_act
> > Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_320_act
> >
> > The input contained 5 matches.
> > ====================================================================
> > ==
> >
> > Now the question is how to uniquely identify first match.
>
> Match No is described here:
>
> http://jakarta.apache.org/jmeter/usermanual/component_reference.html#R
> eg
> ular_Expression_Extractor
>
> > I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and

> > some other sources to figure out how to uniquely name the match.
> > Can you please give me pointers..
> >
> > So now instead of ${VehicleNumber} I have to give something else...
> >
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 10:36 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > This can be seen in the Tree View Listener, or you can use Save 
> > Responses to a File Post-Processor.
> >
> > These are described in the manual ...
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Is there a way to print the text the regular expression is trying 
> > > to
>
> > > compare ( I mean to the whole page content which RE is going 
> > > after)
> > >
> > > -----Original Message-----
> > > From: sebb [mailto:sebbaz@gmail.com]
> > > Sent: Wednesday, November 14, 2007 9:18 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Have you tried the page content in the ORO demo?
> > >
> > > Note that the spacing is critical.
> > >
> > > You may need to replace white-space in the RE with \s+ - or even 
> > > \s*
>
> > > if the space might be absent.
> > >
> > > On 14/11/2007, Modha Khammammettu <MK...@calcas.com>
wrote:
> > > > Here is the page content
> > > >
> > > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> > width="9"
> > > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > > height="4"/></td>
> > > > <td><button smokeId="Add" 
> > > > onclick="Events.invokeEvent('5_290_act',
> > > > true)" class="button">Add</button></td><td><button
> smokeId="Remove"
> > > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all

> > > > Removeable" class="button">Remove</button></td></tr>
> > > > </table>
> > > >
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > > To: JMeter Users List
> > > > Subject: RE: Regular Expression -- Help
> > > >
> > > > Thanks
> > > > I put it as $1$ only.
> > > >
> > > > When I put a default value as descr I get VehicleNumber: descr
> > > >
> > > > -----Original Message-----
> > > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > > To: JMeter Users List
> > > > Subject: Re: Regular Expression -- Help
> > > >
> > > > Modha Khammammettu wrote:
> > > > > Thanks
> > > > > This works fine when I tried it in ORO demo.
> > > > > But when I tried the same thing in Jmeter script and print it 
> > > > > as
>
> > > > > Java Request I get it as
> > > > >
> > > > > VehicleNumber: {${VehicleNumber} as result.
> > > > > All other variables print just fine.
> > > > >
> > > > > I have the java request defined as follows
> > > > >
> > > > > Reference Name: VehicleNumber
> > > > > RE: invokeEvent\('([^']+)', true\)" 
> > > > > class="button">Add</button>
> > > > > Template: 1$1
> > > >
> > > > ^ You had this right in your previous post - it should be: $1$
> > > >
> > > > > Match No : 1
> > > > >
> > > > > When I am printing using "Java Request" I set the label as
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > >
> > > > > When I run my test the output is
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > > I expected
> > > > > VehicleNumber: 5_290_act
> > > > >
> > > > > I saw the page content in view result tree, it has the string 
> > > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > > >
> > > > > It is just happening with this particular variable.
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ronan Klyne
> > > > Business Collaborator Developer
> > > > Tel: +44 (0)870 163 2555
> > > > ronan.klyne@groupbc.com
> > > > www.groupbc.com
> > > >
> > > > ----------------------------------------------------------------
> > > > --
> > > > --
> > > > - 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
> > > >
> > > >
> > > > ----------------------------------------------------------------
> > > > --
> > > > --
> > > > - 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
> > >
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> >
> >
> > --------------------------------------------------------------------
> > - 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
>
>
> ---------------------------------------------------------------------
> 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


---------------------------------------------------------------------
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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
I always have match no set to 1

Reference Name: VehicleNumber
RE: invokeEvent\('(.*?)', true\)" class="button">Add</button>
Template: $1$
Match No: 1
Default Value : descr

The label is set to VehicleNumber: ${VehicleNumber_1_g1 
Status : FAIL


-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 12:19 PM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

If you want to match a particular instance of a pattern, then use the
Match No - as described previously.

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Thanks sebb for your patience.
>
> I tried all possible combinations I can think of like..
>
> VehicleNumber: ${VehicleNumber_1_g1}
> VehicleNumber: ${VehicleNumber_1_g0}
> VehicleNumber: ${VehicleNumber_1}
> Etc
>
> It prints as it is like ${VehicleNumber_1_g1}, ${VehicleNumber_1_g0} 
> etc instead of 5_290_act
>
> Lack of samples in the Jmeter page is making particularly hard for
me...
>
> Can you please tell me where I went wrong?
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 11:11 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Ok I know (?) the problem
> >
> > There are 5 matches to the regular expression ( when I put the whole

> > page as input to ORO)
> >
> > ===================================================================
> > Compiling regular expression.
> >
> > Searching
> >
> > Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_290_act
> > Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_299_act
> > Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_306_act
> > Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_314_act
> > Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_320_act
> >
> > The input contained 5 matches.
> > ====================================================================
> > ==
> >
> > Now the question is how to uniquely identify first match.
>
> Match No is described here:
>
> http://jakarta.apache.org/jmeter/usermanual/component_reference.html#R
> eg
> ular_Expression_Extractor
>
> > I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and

> > some other sources to figure out how to uniquely name the match.
> > Can you please give me pointers..
> >
> > So now instead of ${VehicleNumber} I have to give something else...
> >
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 10:36 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > This can be seen in the Tree View Listener, or you can use Save 
> > Responses to a File Post-Processor.
> >
> > These are described in the manual ...
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Is there a way to print the text the regular expression is trying 
> > > to
>
> > > compare ( I mean to the whole page content which RE is going 
> > > after)
> > >
> > > -----Original Message-----
> > > From: sebb [mailto:sebbaz@gmail.com]
> > > Sent: Wednesday, November 14, 2007 9:18 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Have you tried the page content in the ORO demo?
> > >
> > > Note that the spacing is critical.
> > >
> > > You may need to replace white-space in the RE with \s+ - or even 
> > > \s*
>
> > > if the space might be absent.
> > >
> > > On 14/11/2007, Modha Khammammettu <MK...@calcas.com>
wrote:
> > > > Here is the page content
> > > >
> > > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> > width="9"
> > > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > > height="4"/></td>
> > > > <td><button smokeId="Add" 
> > > > onclick="Events.invokeEvent('5_290_act',
> > > > true)" class="button">Add</button></td><td><button
> smokeId="Remove"
> > > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all

> > > > Removeable" class="button">Remove</button></td></tr>
> > > > </table>
> > > >
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > > To: JMeter Users List
> > > > Subject: RE: Regular Expression -- Help
> > > >
> > > > Thanks
> > > > I put it as $1$ only.
> > > >
> > > > When I put a default value as descr I get VehicleNumber: descr
> > > >
> > > > -----Original Message-----
> > > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > > To: JMeter Users List
> > > > Subject: Re: Regular Expression -- Help
> > > >
> > > > Modha Khammammettu wrote:
> > > > > Thanks
> > > > > This works fine when I tried it in ORO demo.
> > > > > But when I tried the same thing in Jmeter script and print it 
> > > > > as
>
> > > > > Java Request I get it as
> > > > >
> > > > > VehicleNumber: {${VehicleNumber} as result.
> > > > > All other variables print just fine.
> > > > >
> > > > > I have the java request defined as follows
> > > > >
> > > > > Reference Name: VehicleNumber
> > > > > RE: invokeEvent\('([^']+)', true\)" 
> > > > > class="button">Add</button>
> > > > > Template: 1$1
> > > >
> > > > ^ You had this right in your previous post - it should be: $1$
> > > >
> > > > > Match No : 1
> > > > >
> > > > > When I am printing using "Java Request" I set the label as
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > >
> > > > > When I run my test the output is
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > > I expected
> > > > > VehicleNumber: 5_290_act
> > > > >
> > > > > I saw the page content in view result tree, it has the string 
> > > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > > >
> > > > > It is just happening with this particular variable.
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ronan Klyne
> > > > Business Collaborator Developer
> > > > Tel: +44 (0)870 163 2555
> > > > ronan.klyne@groupbc.com
> > > > www.groupbc.com
> > > >
> > > > ----------------------------------------------------------------
> > > > --
> > > > --
> > > > - 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
> > > >
> > > >
> > > > ----------------------------------------------------------------
> > > > --
> > > > --
> > > > - 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
> > >
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> >
> >
> > --------------------------------------------------------------------
> > - 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
>
>
> ---------------------------------------------------------------------
> 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


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


Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
If you want to match a particular instance of a pattern, then use the
Match No - as described previously.

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Thanks sebb for your patience.
>
> I tried all possible combinations I can think of like..
>
> VehicleNumber: ${VehicleNumber_1_g1}
> VehicleNumber: ${VehicleNumber_1_g0}
> VehicleNumber: ${VehicleNumber_1}
> Etc
>
> It prints as it is like ${VehicleNumber_1_g1}, ${VehicleNumber_1_g0} etc
> instead of 5_290_act
>
> Lack of samples in the Jmeter page is making particularly hard for me...
>
> Can you please tell me where I went wrong?
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 11:11 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Ok I know (?) the problem
> >
> > There are 5 matches to the regular expression ( when I put the whole
> > page as input to ORO)
> >
> > ===================================================================
> > Compiling regular expression.
> >
> > Searching
> >
> > Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_290_act
> > Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_299_act
> > Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_306_act
> > Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_314_act
> > Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
> >    Subgroups:
> >    1: 5_320_act
> >
> > The input contained 5 matches.
> > ======================================================================
> >
> > Now the question is how to uniquely identify first match.
>
> Match No is described here:
>
> http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Reg
> ular_Expression_Extractor
>
> > I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and
> > some other sources to figure out how to uniquely name the match.
> > Can you please give me pointers..
> >
> > So now instead of ${VehicleNumber} I have to give something else...
> >
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 10:36 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > This can be seen in the Tree View Listener, or you can use Save
> > Responses to a File Post-Processor.
> >
> > These are described in the manual ...
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Is there a way to print the text the regular expression is trying to
>
> > > compare ( I mean to the whole page content which RE is going after)
> > >
> > > -----Original Message-----
> > > From: sebb [mailto:sebbaz@gmail.com]
> > > Sent: Wednesday, November 14, 2007 9:18 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Have you tried the page content in the ORO demo?
> > >
> > > Note that the spacing is critical.
> > >
> > > You may need to replace white-space in the RE with \s+ - or even \s*
>
> > > if the space might be absent.
> > >
> > > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > > Here is the page content
> > > >
> > > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> > width="9"
> > > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > > height="4"/></td>
> > > > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > > > true)" class="button">Add</button></td><td><button
> smokeId="Remove"
> > > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all
> > > > Removeable" class="button">Remove</button></td></tr>
> > > > </table>
> > > >
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > > To: JMeter Users List
> > > > Subject: RE: Regular Expression -- Help
> > > >
> > > > Thanks
> > > > I put it as $1$ only.
> > > >
> > > > When I put a default value as descr I get VehicleNumber: descr
> > > >
> > > > -----Original Message-----
> > > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > > To: JMeter Users List
> > > > Subject: Re: Regular Expression -- Help
> > > >
> > > > Modha Khammammettu wrote:
> > > > > Thanks
> > > > > This works fine when I tried it in ORO demo.
> > > > > But when I tried the same thing in Jmeter script and print it as
>
> > > > > Java Request I get it as
> > > > >
> > > > > VehicleNumber: {${VehicleNumber} as result.
> > > > > All other variables print just fine.
> > > > >
> > > > > I have the java request defined as follows
> > > > >
> > > > > Reference Name: VehicleNumber
> > > > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > > > Template: 1$1
> > > >
> > > > ^ You had this right in your previous post - it should be: $1$
> > > >
> > > > > Match No : 1
> > > > >
> > > > > When I am printing using "Java Request" I set the label as
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > >
> > > > > When I run my test the output is
> > > > > VehicleNumber: ${VehicleNumber}
> > > > >
> > > > > I expected
> > > > > VehicleNumber: 5_290_act
> > > > >
> > > > > I saw the page content in view result tree, it has the string
> > > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > > >
> > > > > It is just happening with this particular variable.
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ronan Klyne
> > > > Business Collaborator Developer
> > > > Tel: +44 (0)870 163 2555
> > > > ronan.klyne@groupbc.com
> > > > www.groupbc.com
> > > >
> > > > ------------------------------------------------------------------
> > > > --
> > > > - 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
> > > >
> > > >
> > > > ------------------------------------------------------------------
> > > > --
> > > > - 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
> > >
> > >
> > > --------------------------------------------------------------------
> > > - 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
> >
> >
> > ---------------------------------------------------------------------
> > 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
>
>
> ---------------------------------------------------------------------
> 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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Now it does not print default..
So I guess it matched  

-----Original Message-----
From: Modha Khammammettu [mailto:MKhammammettu@calcas.com] 
Sent: Wednesday, November 14, 2007 12:14 PM
To: JMeter Users List
Subject: RE: Regular Expression -- Help

Thanks sebb for your patience.

I tried all possible combinations I can think of like..

VehicleNumber: ${VehicleNumber_1_g1}
VehicleNumber: ${VehicleNumber_1_g0}
VehicleNumber: ${VehicleNumber_1}
Etc

It prints as it is like ${VehicleNumber_1_g1}, ${VehicleNumber_1_g0} etc
instead of 5_290_act

Lack of samples in the Jmeter page is making particularly hard for me...

Can you please tell me where I went wrong? 

-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com]
Sent: Wednesday, November 14, 2007 11:11 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Ok I know (?) the problem
>
> There are 5 matches to the regular expression ( when I put the whole 
> page as input to ORO)
>
> ===================================================================
> Compiling regular expression.
>
> Searching
>
> Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_290_act
> Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_299_act
> Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_306_act
> Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_314_act
> Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_320_act
>
> The input contained 5 matches.
> ======================================================================
>
> Now the question is how to uniquely identify first match.

Match No is described here:

http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Reg
ular_Expression_Extractor

> I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and 
> some other sources to figure out how to uniquely name the match.
> Can you please give me pointers..
>
> So now instead of ${VehicleNumber} I have to give something else...
>
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 10:36 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> This can be seen in the Tree View Listener, or you can use Save 
> Responses to a File Post-Processor.
>
> These are described in the manual ...
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Is there a way to print the text the regular expression is trying to

> > compare ( I mean to the whole page content which RE is going after)
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 9:18 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > Have you tried the page content in the ORO demo?
> >
> > Note that the spacing is critical.
> >
> > You may need to replace white-space in the RE with \s+ - or even \s*

> > if the space might be absent.
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Here is the page content
> > >
> > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> width="9"
> > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > height="4"/></td>
> > > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > > true)" class="button">Add</button></td><td><button
smokeId="Remove"
> > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all 
> > > Removeable" class="button">Remove</button></td></tr>
> > > </table>
> > >
> > >
> > >
> > > -----Original Message-----
> > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > To: JMeter Users List
> > > Subject: RE: Regular Expression -- Help
> > >
> > > Thanks
> > > I put it as $1$ only.
> > >
> > > When I put a default value as descr I get VehicleNumber: descr
> > >
> > > -----Original Message-----
> > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Modha Khammammettu wrote:
> > > > Thanks
> > > > This works fine when I tried it in ORO demo.
> > > > But when I tried the same thing in Jmeter script and print it as

> > > > Java Request I get it as
> > > >
> > > > VehicleNumber: {${VehicleNumber} as result.
> > > > All other variables print just fine.
> > > >
> > > > I have the java request defined as follows
> > > >
> > > > Reference Name: VehicleNumber
> > > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > > Template: 1$1
> > >
> > > ^ You had this right in your previous post - it should be: $1$
> > >
> > > > Match No : 1
> > > >
> > > > When I am printing using "Java Request" I set the label as
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > >
> > > > When I run my test the output is
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > > I expected
> > > > VehicleNumber: 5_290_act
> > > >
> > > > I saw the page content in view result tree, it has the string 
> > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > >
> > > > It is just happening with this particular variable.
> > > >
> > >
> > >
> > >
> > > --
> > > Ronan Klyne
> > > Business Collaborator Developer
> > > Tel: +44 (0)870 163 2555
> > > ronan.klyne@groupbc.com
> > > www.groupbc.com
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> > >
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> >
> >
> > --------------------------------------------------------------------
> > - 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
>
>
> ---------------------------------------------------------------------
> 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


---------------------------------------------------------------------
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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Thanks sebb for your patience.

I tried all possible combinations I can think of like..

VehicleNumber: ${VehicleNumber_1_g1}
VehicleNumber: ${VehicleNumber_1_g0}
VehicleNumber: ${VehicleNumber_1}
Etc

It prints as it is like ${VehicleNumber_1_g1}, ${VehicleNumber_1_g0} etc
instead of 5_290_act

Lack of samples in the Jmeter page is making particularly hard for me...

Can you please tell me where I went wrong? 

-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 11:11 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Ok I know (?) the problem
>
> There are 5 matches to the regular expression ( when I put the whole 
> page as input to ORO)
>
> ===================================================================
> Compiling regular expression.
>
> Searching
>
> Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_290_act
> Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_299_act
> Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_306_act
> Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_314_act
> Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_320_act
>
> The input contained 5 matches.
> ======================================================================
>
> Now the question is how to uniquely identify first match.

Match No is described here:

http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Reg
ular_Expression_Extractor

> I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and 
> some other sources to figure out how to uniquely name the match.
> Can you please give me pointers..
>
> So now instead of ${VehicleNumber} I have to give something else...
>
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 10:36 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> This can be seen in the Tree View Listener, or you can use Save 
> Responses to a File Post-Processor.
>
> These are described in the manual ...
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Is there a way to print the text the regular expression is trying to

> > compare ( I mean to the whole page content which RE is going after)
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 9:18 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > Have you tried the page content in the ORO demo?
> >
> > Note that the spacing is critical.
> >
> > You may need to replace white-space in the RE with \s+ - or even \s*

> > if the space might be absent.
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Here is the page content
> > >
> > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> width="9"
> > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > height="4"/></td>
> > > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > > true)" class="button">Add</button></td><td><button
smokeId="Remove"
> > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all 
> > > Removeable" class="button">Remove</button></td></tr>
> > > </table>
> > >
> > >
> > >
> > > -----Original Message-----
> > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > To: JMeter Users List
> > > Subject: RE: Regular Expression -- Help
> > >
> > > Thanks
> > > I put it as $1$ only.
> > >
> > > When I put a default value as descr I get VehicleNumber: descr
> > >
> > > -----Original Message-----
> > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Modha Khammammettu wrote:
> > > > Thanks
> > > > This works fine when I tried it in ORO demo.
> > > > But when I tried the same thing in Jmeter script and print it as

> > > > Java Request I get it as
> > > >
> > > > VehicleNumber: {${VehicleNumber} as result.
> > > > All other variables print just fine.
> > > >
> > > > I have the java request defined as follows
> > > >
> > > > Reference Name: VehicleNumber
> > > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > > Template: 1$1
> > >
> > > ^ You had this right in your previous post - it should be: $1$
> > >
> > > > Match No : 1
> > > >
> > > > When I am printing using "Java Request" I set the label as
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > >
> > > > When I run my test the output is
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > > I expected
> > > > VehicleNumber: 5_290_act
> > > >
> > > > I saw the page content in view result tree, it has the string 
> > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > >
> > > > It is just happening with this particular variable.
> > > >
> > >
> > >
> > >
> > > --
> > > Ronan Klyne
> > > Business Collaborator Developer
> > > Tel: +44 (0)870 163 2555
> > > ronan.klyne@groupbc.com
> > > www.groupbc.com
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> > >
> > >
> > > ------------------------------------------------------------------
> > > --
> > > - 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
> >
> >
> > --------------------------------------------------------------------
> > - 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
>
>
> ---------------------------------------------------------------------
> 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


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


Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Ok I know (?) the problem
>
> There are 5 matches to the regular expression ( when I put the whole
> page as input to ORO)
>
> ===================================================================
> Compiling regular expression.
>
> Searching
>
> Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_290_act
> Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_299_act
> Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_306_act
> Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_314_act
> Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
>    Subgroups:
>    1: 5_320_act
>
> The input contained 5 matches.
> ======================================================================
>
> Now the question is how to uniquely identify first match.

Match No is described here:

http://jakarta.apache.org/jmeter/usermanual/component_reference.html#Regular_Expression_Extractor

> I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and
> some other sources to figure out how to uniquely name the match.
> Can you please give me pointers..
>
> So now instead of ${VehicleNumber} I have to give something else...
>
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 10:36 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> This can be seen in the Tree View Listener, or you can use Save
> Responses to a File Post-Processor.
>
> These are described in the manual ...
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Is there a way to print the text the regular expression is trying to
> > compare ( I mean to the whole page content which RE is going after)
> >
> > -----Original Message-----
> > From: sebb [mailto:sebbaz@gmail.com]
> > Sent: Wednesday, November 14, 2007 9:18 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > Have you tried the page content in the ORO demo?
> >
> > Note that the spacing is critical.
> >
> > You may need to replace white-space in the RE with \s+ - or even \s*
> > if the space might be absent.
> >
> > On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > > Here is the page content
> > >
> > > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
> width="9"
> > > height="1"><img src="images/trans_pixel.gif" width="4"
> > > height="4"/></td>
> > > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > > true)" class="button">Add</button></td><td><button smokeId="Remove"
> > > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all
> > > Removeable" class="button">Remove</button></td></tr>
> > > </table>
> > >
> > >
> > >
> > > -----Original Message-----
> > > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > > Sent: Wednesday, November 14, 2007 9:08 AM
> > > To: JMeter Users List
> > > Subject: RE: Regular Expression -- Help
> > >
> > > Thanks
> > > I put it as $1$ only.
> > >
> > > When I put a default value as descr
> > > I get VehicleNumber: descr
> > >
> > > -----Original Message-----
> > > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > > Sent: Wednesday, November 14, 2007 9:00 AM
> > > To: JMeter Users List
> > > Subject: Re: Regular Expression -- Help
> > >
> > > Modha Khammammettu wrote:
> > > > Thanks
> > > > This works fine when I tried it in ORO demo.
> > > > But when I tried the same thing in Jmeter script and print it as
> > > > Java Request I get it as
> > > >
> > > > VehicleNumber: {${VehicleNumber} as result.
> > > > All other variables print just fine.
> > > >
> > > > I have the java request defined as follows
> > > >
> > > > Reference Name: VehicleNumber
> > > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > > Template: 1$1
> > >
> > > ^ You had this right in your previous post - it should be: $1$
> > >
> > > > Match No : 1
> > > >
> > > > When I am printing using "Java Request" I set the label as
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > >
> > > > When I run my test the output is
> > > > VehicleNumber: ${VehicleNumber}
> > > >
> > > > I expected
> > > > VehicleNumber: 5_290_act
> > > >
> > > > I saw the page content in view result tree, it has the string
> > > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > > >
> > > > It is just happening with this particular variable.
> > > >
> > >
> > >
> > >
> > > --
> > > Ronan Klyne
> > > Business Collaborator Developer
> > > Tel: +44 (0)870 163 2555
> > > ronan.klyne@groupbc.com
> > > www.groupbc.com
> > >
> > > --------------------------------------------------------------------
> > > - 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
> > >
> > >
> > > --------------------------------------------------------------------
> > > - 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
> >
> >
> > ---------------------------------------------------------------------
> > 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
>
>
> ---------------------------------------------------------------------
> 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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Ok I know (?) the problem

There are 5 matches to the regular expression ( when I put the whole
page as input to ORO)

===================================================================
Compiling regular expression.

Searching

Match 1: invokeEvent('5_290_act', true)" class="button">Add</button>
    Subgroups:
    1: 5_290_act
Match 2: invokeEvent('5_299_act', true)" class="button">Add</button>
    Subgroups:
    1: 5_299_act
Match 3: invokeEvent('5_306_act', true)" class="button">Add</button>
    Subgroups:
    1: 5_306_act
Match 4: invokeEvent('5_314_act', true)" class="button">Add</button>
    Subgroups:
    1: 5_314_act
Match 5: invokeEvent('5_320_act', true)" class="button">Add</button>
    Subgroups:
    1: 5_320_act

The input contained 5 matches. 
======================================================================

Now the question is how to uniquely identify first match.

I tried http://wiki.apache.org/jakarta-jmeter/RegularExpressions and
some other sources to figure out how to uniquely name the match.
Can you please give me pointers..

So now instead of ${VehicleNumber} I have to give something else...


-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 10:36 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

This can be seen in the Tree View Listener, or you can use Save
Responses to a File Post-Processor.

These are described in the manual ...

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Is there a way to print the text the regular expression is trying to 
> compare ( I mean to the whole page content which RE is going after)
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 9:18 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> Have you tried the page content in the ORO demo?
>
> Note that the spacing is critical.
>
> You may need to replace white-space in the RE with \s+ - or even \s* 
> if the space might be absent.
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Here is the page content
> >
> > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td
width="9"
> > height="1"><img src="images/trans_pixel.gif" width="4"
> > height="4"/></td>
> > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > true)" class="button">Add</button></td><td><button smokeId="Remove"
> > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all 
> > Removeable" class="button">Remove</button></td></tr>
> > </table>
> >
> >
> >
> > -----Original Message-----
> > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > Sent: Wednesday, November 14, 2007 9:08 AM
> > To: JMeter Users List
> > Subject: RE: Regular Expression -- Help
> >
> > Thanks
> > I put it as $1$ only.
> >
> > When I put a default value as descr
> > I get VehicleNumber: descr
> >
> > -----Original Message-----
> > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > Sent: Wednesday, November 14, 2007 9:00 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > Modha Khammammettu wrote:
> > > Thanks
> > > This works fine when I tried it in ORO demo.
> > > But when I tried the same thing in Jmeter script and print it as 
> > > Java Request I get it as
> > >
> > > VehicleNumber: {${VehicleNumber} as result.
> > > All other variables print just fine.
> > >
> > > I have the java request defined as follows
> > >
> > > Reference Name: VehicleNumber
> > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > Template: 1$1
> >
> > ^ You had this right in your previous post - it should be: $1$
> >
> > > Match No : 1
> > >
> > > When I am printing using "Java Request" I set the label as
> > > VehicleNumber: ${VehicleNumber}
> > >
> > >
> > > When I run my test the output is
> > > VehicleNumber: ${VehicleNumber}
> > >
> > > I expected
> > > VehicleNumber: 5_290_act
> > >
> > > I saw the page content in view result tree, it has the string 
> > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > >
> > > It is just happening with this particular variable.
> > >
> >
> >
> >
> > --
> > Ronan Klyne
> > Business Collaborator Developer
> > Tel: +44 (0)870 163 2555
> > ronan.klyne@groupbc.com
> > www.groupbc.com
> >
> > --------------------------------------------------------------------
> > - 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
> >
> >
> > --------------------------------------------------------------------
> > - 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
>
>
> ---------------------------------------------------------------------
> 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


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


Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
This can be seen in the Tree View Listener, or you can use Save
Responses to a File Post-Processor.

These are described in the manual ...

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Is there a way to print the text the regular expression is trying to
> compare ( I mean to the whole page content which RE is going after)
>
> -----Original Message-----
> From: sebb [mailto:sebbaz@gmail.com]
> Sent: Wednesday, November 14, 2007 9:18 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> Have you tried the page content in the ORO demo?
>
> Note that the spacing is critical.
>
> You may need to replace white-space in the RE with \s+ - or even \s* if
> the space might be absent.
>
> On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> > Here is the page content
> >
> > <table cellpadding="0" cellspacing="0" border="0"> <tr> <td width="9"
> > height="1"><img src="images/trans_pixel.gif" width="4"
> > height="4"/></td>
> > <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> > true)" class="button">Add</button></td><td><button smokeId="Remove"
> > onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all
> > Removeable" class="button">Remove</button></td></tr>
> > </table>
> >
> >
> >
> > -----Original Message-----
> > From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> > Sent: Wednesday, November 14, 2007 9:08 AM
> > To: JMeter Users List
> > Subject: RE: Regular Expression -- Help
> >
> > Thanks
> > I put it as $1$ only.
> >
> > When I put a default value as descr
> > I get VehicleNumber: descr
> >
> > -----Original Message-----
> > From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> > Sent: Wednesday, November 14, 2007 9:00 AM
> > To: JMeter Users List
> > Subject: Re: Regular Expression -- Help
> >
> > Modha Khammammettu wrote:
> > > Thanks
> > > This works fine when I tried it in ORO demo.
> > > But when I tried the same thing in Jmeter script and print it as
> > > Java Request I get it as
> > >
> > > VehicleNumber: {${VehicleNumber} as result.
> > > All other variables print just fine.
> > >
> > > I have the java request defined as follows
> > >
> > > Reference Name: VehicleNumber
> > > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > > Template: 1$1
> >
> > ^ You had this right in your previous post - it should be: $1$
> >
> > > Match No : 1
> > >
> > > When I am printing using "Java Request" I set the label as
> > > VehicleNumber: ${VehicleNumber}
> > >
> > >
> > > When I run my test the output is
> > > VehicleNumber: ${VehicleNumber}
> > >
> > > I expected
> > > VehicleNumber: 5_290_act
> > >
> > > I saw the page content in view result tree, it has the string
> > > invokeEvent('5_290_act', true)" class="button">Add</button>
> > >
> > > It is just happening with this particular variable.
> > >
> >
> >
> >
> > --
> > Ronan Klyne
> > Business Collaborator Developer
> > Tel: +44 (0)870 163 2555
> > ronan.klyne@groupbc.com
> > www.groupbc.com
> >
> > ---------------------------------------------------------------------
> > 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
> >
> >
> > ---------------------------------------------------------------------
> > 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
>
>
> ---------------------------------------------------------------------
> 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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Is there a way to print the text the regular expression is trying to
compare ( I mean to the whole page content which RE is going after) 

-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 9:18 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

Have you tried the page content in the ORO demo?

Note that the spacing is critical.

You may need to replace white-space in the RE with \s+ - or even \s* if
the space might be absent.

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Here is the page content
>
> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td width="9" 
> height="1"><img src="images/trans_pixel.gif" width="4"
> height="4"/></td>
> <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> true)" class="button">Add</button></td><td><button smokeId="Remove"
> onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all 
> Removeable" class="button">Remove</button></td></tr>
> </table>
>
>
>
> -----Original Message-----
> From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> Sent: Wednesday, November 14, 2007 9:08 AM
> To: JMeter Users List
> Subject: RE: Regular Expression -- Help
>
> Thanks
> I put it as $1$ only.
>
> When I put a default value as descr
> I get VehicleNumber: descr
>
> -----Original Message-----
> From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> Sent: Wednesday, November 14, 2007 9:00 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> Modha Khammammettu wrote:
> > Thanks
> > This works fine when I tried it in ORO demo.
> > But when I tried the same thing in Jmeter script and print it as 
> > Java Request I get it as
> >
> > VehicleNumber: {${VehicleNumber} as result.
> > All other variables print just fine.
> >
> > I have the java request defined as follows
> >
> > Reference Name: VehicleNumber
> > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > Template: 1$1
>
> ^ You had this right in your previous post - it should be: $1$
>
> > Match No : 1
> >
> > When I am printing using "Java Request" I set the label as
> > VehicleNumber: ${VehicleNumber}
> >
> >
> > When I run my test the output is
> > VehicleNumber: ${VehicleNumber}
> >
> > I expected
> > VehicleNumber: 5_290_act
> >
> > I saw the page content in view result tree, it has the string 
> > invokeEvent('5_290_act', true)" class="button">Add</button>
> >
> > It is just happening with this particular variable.
> >
>
>
>
> --
> Ronan Klyne
> Business Collaborator Developer
> Tel: +44 (0)870 163 2555
> ronan.klyne@groupbc.com
> www.groupbc.com
>
> ---------------------------------------------------------------------
> 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
>
>
> ---------------------------------------------------------------------
> 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


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


Re: Regular Expression -- Help

Posted by sebb <se...@gmail.com>.
Have you tried the page content in the ORO demo?

Note that the spacing is critical.

You may need to replace white-space in the RE with \s+ - or even \s*
if the space might be absent.

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Here is the page content
>
> <table cellpadding="0" cellspacing="0" border="0">
> <tr>
> <td width="9" height="1"><img src="images/trans_pixel.gif" width="4"
> height="4"/></td>
> <td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
> true)" class="button">Add</button></td><td><button smokeId="Remove"
> onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all
> Removeable" class="button">Remove</button></td></tr>
> </table>
>
>
>
> -----Original Message-----
> From: Modha Khammammettu [mailto:MKhammammettu@calcas.com]
> Sent: Wednesday, November 14, 2007 9:08 AM
> To: JMeter Users List
> Subject: RE: Regular Expression -- Help
>
> Thanks
> I put it as $1$ only.
>
> When I put a default value as descr
> I get VehicleNumber: descr
>
> -----Original Message-----
> From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
> Sent: Wednesday, November 14, 2007 9:00 AM
> To: JMeter Users List
> Subject: Re: Regular Expression -- Help
>
> Modha Khammammettu wrote:
> > Thanks
> > This works fine when I tried it in ORO demo.
> > But when I tried the same thing in Jmeter script and print it as Java
> > Request I get it as
> >
> > VehicleNumber: {${VehicleNumber} as result.
> > All other variables print just fine.
> >
> > I have the java request defined as follows
> >
> > Reference Name: VehicleNumber
> > RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> > Template: 1$1
>
> ^ You had this right in your previous post - it should be: $1$
>
> > Match No : 1
> >
> > When I am printing using "Java Request" I set the label as
> > VehicleNumber: ${VehicleNumber}
> >
> >
> > When I run my test the output is
> > VehicleNumber: ${VehicleNumber}
> >
> > I expected
> > VehicleNumber: 5_290_act
> >
> > I saw the page content in view result tree, it has the string
> > invokeEvent('5_290_act', true)" class="button">Add</button>
> >
> > It is just happening with this particular variable.
> >
>
>
>
> --
> Ronan Klyne
> Business Collaborator Developer
> Tel: +44 (0)870 163 2555
> ronan.klyne@groupbc.com
> www.groupbc.com
>
> ---------------------------------------------------------------------
> 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
>
>
> ---------------------------------------------------------------------
> 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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Here is the page content

<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td width="9" height="1"><img src="images/trans_pixel.gif" width="4"
height="4"/></td>
<td><button smokeId="Add" onclick="Events.invokeEvent('5_290_act',
true)" class="button">Add</button></td><td><button smokeId="Remove"
onclick="Events.invokeEvent('5_291_act', true)" buttonFlags="all
Removeable" class="button">Remove</button></td></tr>
</table>

 

-----Original Message-----
From: Modha Khammammettu [mailto:MKhammammettu@calcas.com] 
Sent: Wednesday, November 14, 2007 9:08 AM
To: JMeter Users List
Subject: RE: Regular Expression -- Help

Thanks
I put it as $1$ only.

When I put a default value as descr
I get VehicleNumber: descr 

-----Original Message-----
From: Ronan Klyne [mailto:ronan.klyne@groupbc.com]
Sent: Wednesday, November 14, 2007 9:00 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

Modha Khammammettu wrote:
> Thanks
> This works fine when I tried it in ORO demo.
> But when I tried the same thing in Jmeter script and print it as Java 
> Request I get it as
> 
> VehicleNumber: {${VehicleNumber} as result.
> All other variables print just fine.
> 
> I have the java request defined as follows
> 
> Reference Name: VehicleNumber
> RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> Template: 1$1

^ You had this right in your previous post - it should be: $1$

> Match No : 1
> 
> When I am printing using "Java Request" I set the label as
> VehicleNumber: ${VehicleNumber}
> 
> 
> When I run my test the output is
> VehicleNumber: ${VehicleNumber}
> 
> I expected
> VehicleNumber: 5_290_act
> 
> I saw the page content in view result tree, it has the string 
> invokeEvent('5_290_act', true)" class="button">Add</button>
> 
> It is just happening with this particular variable.
> 



--
Ronan Klyne
Business Collaborator Developer
Tel: +44 (0)870 163 2555
ronan.klyne@groupbc.com
www.groupbc.com

---------------------------------------------------------------------
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


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


RE: Regular Expression -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Thanks
I put it as $1$ only.

When I put a default value as descr
I get VehicleNumber: descr 

-----Original Message-----
From: Ronan Klyne [mailto:ronan.klyne@groupbc.com] 
Sent: Wednesday, November 14, 2007 9:00 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

Modha Khammammettu wrote:
> Thanks
> This works fine when I tried it in ORO demo.
> But when I tried the same thing in Jmeter script and print it as Java 
> Request I get it as
> 
> VehicleNumber: {${VehicleNumber} as result.
> All other variables print just fine.
> 
> I have the java request defined as follows
> 
> Reference Name: VehicleNumber
> RE: invokeEvent\('([^']+)', true\)" class="button">Add</button>
> Template: 1$1

^ You had this right in your previous post - it should be: $1$

> Match No : 1
> 
> When I am printing using "Java Request" I set the label as
> VehicleNumber: ${VehicleNumber}
> 
> 
> When I run my test the output is
> VehicleNumber: ${VehicleNumber}
> 
> I expected
> VehicleNumber: 5_290_act
> 
> I saw the page content in view result tree, it has the string 
> invokeEvent('5_290_act', true)" class="button">Add</button>
> 
> It is just happening with this particular variable.
> 



--
Ronan Klyne
Business Collaborator Developer
Tel: +44 (0)870 163 2555
ronan.klyne@groupbc.com
www.groupbc.com

---------------------------------------------------------------------
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 -- Help

Posted by Ronan Klyne <ro...@groupbc.com>.
Modha Khammammettu wrote:
> Thanks
> This works fine when I tried it in ORO demo.
> But when I tried the same thing in Jmeter script and print it as Java
> Request I get it as
> 
> VehicleNumber: {${VehicleNumber} as result.
> All other variables print just fine.
> 
> I have the java request defined as follows
> 
> Reference Name: VehicleNumber
> RE: invokeEvent\('([^']+)', true\)" class="button">Add</button> 
> Template: 1$1

^ You had this right in your previous post - it should be: $1$

> Match No : 1
> 
> When I am printing using "Java Request" I set the label as 
> VehicleNumber: ${VehicleNumber}
> 
> 
> When I run my test the output is
> VehicleNumber: ${VehicleNumber}
> 
> I expected 
> VehicleNumber: 5_290_act 
> 
> I saw the page content in view result tree, it has the string 
> invokeEvent('5_290_act', true)" class="button">Add</button>
> 
> It is just happening with this particular variable.
> 



-- 
Ronan Klyne
Business Collaborator Developer
Tel: +44 (0)870 163 2555
ronan.klyne@groupbc.com
www.groupbc.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 -- Help

Posted by Modha Khammammettu <MK...@calcas.com>.
Thanks
This works fine when I tried it in ORO demo.
But when I tried the same thing in Jmeter script and print it as Java
Request I get it as

VehicleNumber: {${VehicleNumber} as result.
All other variables print just fine.

I have the java request defined as follows

Reference Name: VehicleNumber
RE: invokeEvent\('([^']+)', true\)" class="button">Add</button> 
Template: 1$1
Match No : 1

When I am printing using "Java Request" I set the label as 
VehicleNumber: ${VehicleNumber}


When I run my test the output is
VehicleNumber: ${VehicleNumber}

I expected 
VehicleNumber: 5_290_act 

I saw the page content in view result tree, it has the string 
invokeEvent('5_290_act', true)" class="button">Add</button>

It is just happening with this particular variable.

-----Original Message-----
From: sebb [mailto:sebbaz@gmail.com] 
Sent: Wednesday, November 14, 2007 5:53 AM
To: JMeter Users List
Subject: Re: Regular Expression -- Help

On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Hi All
>
> I am trying for
>
> Reference Name: VehicleNumber
> RE: invokeEvent('5_290_act', true)" class="button">Add</button>

If what you have labelled RE is the source you want to match against,
then try

invokeEvent\('([^']+)', true\)" class="button">Add</button>

> Template: $1$
> Match No: 1
>
> I want the ReferenceName to have 5_290_act
>
> I tried a few combinations and when I try to print I do not get what I

> am looking for. Can some one please help.

Have you tried the ORO demo?

http://jakarta.apache.org/oro/demo.html

> Thanks
> Modha/-
>

---------------------------------------------------------------------
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 -- Help

Posted by sebb <se...@gmail.com>.
On 14/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Hi All
>
> I am trying for
>
> Reference Name: VehicleNumber
> RE: invokeEvent('5_290_act', true)" class="button">Add</button>

If what you have labelled RE is the source you want to match against, then try

invokeEvent\('([^']+)', true\)" class="button">Add</button>

> Template: $1$
> Match No: 1
>
> I want the ReferenceName to have 5_290_act
>
> I tried a few combinations and when I try to print I do not get what I
> am looking for. Can some one please help.

Have you tried the ORO demo?

http://jakarta.apache.org/oro/demo.html

> Thanks
> Modha/-
>

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