How to get first 4 digits in a number, with oracle sql
<p>I could do </p>

<pre><code>select substr(to_char(20041111), 1, 4) FROM dual;

2004
</code></pre>

<p>Is there a way without converting to string first?</p>