title: how to convert system.linq.IQueryable<int?> to int?[]
body: <pre><code>foreach (var app in allList)
  {
      int?[] ids = Context.tblTransactionDetails
          .Where(x =&gt; x.IsActive == true)
          .Select(x =&gt; x.AdvertID);
  }
  </code></pre>