title: jMeter RegEx JSON response
body: <p>I've read a few tutorials on jMeter RegEx extraction but it's not working. I'm using jMeter 2.7.</p>
  
  <p>I have this JSON:</p>
  
  <pre><code>{"address":{"id":26,"user_id":1,"genre":"billing","first_name":"testFN1","last_name":"testLN1","company":null,"street1":null,"street2":null,"city":null,"state":"DC","zip":null,"country":null,"country_iso2":null,"phone1":"32432424322","phone2":null}}
  </code></pre>
  
  <p>and this RegEx Extractor: "id":(.+?), here's the screenshot of jMeter</p>
  
  <p><img src="https://i.stack.imgur.com/YoFtg.png" alt="enter image description here"></p>
  
  <p>For the extraction, I get <code>$new_address_id</code> = <strong>2</strong>, instead of <strong>26</strong>. Any ideas?</p>
  
  <p><strong>UPDATE 6/26/2012</strong>:</p>
  
  <p>Thanks Cylian for your suggestion. It is very helpful. I ended up changing it to: <code>"id":(\d+)</code>.   </p>
  
  <p>I also did a find a replace in the JMX file for</p>
  
  <pre><code>&lt;stringProp name="RegexExtractor.regex"&gt;&amp;quot;id&amp;quot;:(.+?,)&lt;/stringProp&gt;
  </code></pre>
  
  <p>and replace with</p>
  
  <pre><code>&lt;stringProp name="RegexExtractor.regex"&gt;&amp;quot;id&amp;quot;:(\d+)&lt;/stringProp&gt;
  </code></pre>
  
  <p>Which made the fix quickly. Thanks!</p>