title: Sorting NSArray of dictionaries by value of a key in the dictionaries
body: <p>I have an array populated by dictionaries, and I need to sort the array alphabetically by the values of one of the keys of the dictionaries.</p>
  
  <p>This is my array:</p>
  
  <pre><code>tu dictus: (
      {
      brand = Ryul;
      productTitle = Any;
      quantity = 1;
      subBrand = "Ryul INJ";
      type = Product;
  },
      {
      brand = Trol;
      productTitle = Different;
      quantity = 2;
      subBrand = "";
      type = Brand;
  },
      {
      brand = Dtor;
      productTitle = Any;
      quantity = 1;
      subBrand = "";
      type = Product;
  },
      {
      brand = Ryul;
      productTitle = Different;
      quantity = 2;
      subBrand = "Ryul CHES";
      type = SubBrand;
  },
      {
      brand = Anan;
      productTitle = Any;
      quantity = 1;
      subBrand = "";
      type = Product;
  }
  )
  </code></pre>
  
  <p>Normally for sorting an array I will use </p>
  
  <pre><code>myArray = [uniqueProdsArray sortedArrayUsingSelector:@selector(localizedCaseInsensitiveCompare:)];
  </code></pre>
  
  <p>But how do sort using the <code>brand</code> key of the dictionary?</p>