c# Linq Oracle convert long to string for join
<p>I'm having the following issue, in trying to join up two tables in Oracle.
One of the tables has a string value and the other is a long.</p>

<pre><code>var query = (from d in context.entity
join m in context.entity2
on d.ordernum.Substring(2) equals m.ordernum.ToString())
select new { d.ordernum, d.customer, m.recordkey});
var items = query.ToList();
</code></pre>

<p>The issue is that this does not work with Oracle</p>

<ol>
<li><p>Cant use SQLFunctions as this is an Oracle Database</p></li>
<li><p>Cant use .ToString()</p>

<p>LINQ to Entities does not recognize the method 'System.String ToString()' method, and this method cannot be translated into a store expression.</p></li>
<li><p>Cast use long.Parse()</p>

<p>LINQ to Entities does not recognize the method 'Int64 Parse(System.String)' method, and this method cannot be translated into a store expression.</p></li>
</ol>

<p>Any helps would be appreciated.</p>