title: Finding Max Value of an nvarchar column in sql server 2012 using LINQ
body: <p>I have a table full of serial numbers of a product, the datatype is nvachar, i have entries like 1001, 1002, 1003, abc001, efg002, 1004, def222 . I have to return the <code>max value</code> of the valid numeric numbers in the column, in this case output should be 1004. </p>
  
  <p>This SQL Query is working</p>
  
  <pre><code>select top 1
    cast(SerialNo as integer)
  from [InvSerialItemDetails]
  where isNumeric(SerialNo) = 1
  Order by cast(SerialNo as integer) desc
  </code></pre>
  
  <p>I have to do the same in <code>LINQ</code>. But there is no isNumeric function in LINQ. How to get the same output in <code>LINQ</code> in VB language</p>