I have a large XML file with products inside. I'm trying to delete all products which are out of stock. File size is over 20MB.

```
<product>
  <name>bla1</name>
  <price>50$</price>
  <stock>yes</stock>
  <description>bla</description>
</product>

<product>
  <name>bla2</name>
  <price>60$</price>
  <stock>no</stock>
  <description>bla</description>
</product>

...

```

Is it possible to delete them using Notepad++'s regex or should I use simpleXML(PHP) or something similar?

My basic PHP code:

```
$url = 'input/products.xml';
    $xml = new SimpleXMLElement(file_get_contents($url));

    foreach ($xml->product->children() as $product) {

        //finding out of stock products and deleting them

    }
    $xml->asXml('output/products.xml');

```