title: Getting around the lack of a Left Trim(string, char[]) function in JET / Access
body: <p>I need to remove leading zeros from a string field in an Access database that is destroyed and recreated every time it is used within a C# program. Most string libraries (even SQL ones) include a Trim function to remove leading or following whitespace. Unfortunately, Access does not seem to have a LTrim(string s, char[] trimChars) or something similar. To get around this, I concocted this monstrosity:</p>
  
  <pre><code>Replace(LTrim(Replace(ADDRNO,'0',  ' ')),' ',  '0')
  </code></pre>
  
  <p>But this resulted in an undefined function reference for Replace, even though it is obviously an Access function. </p>
  
  <p>What I am looking for is a way to trim these zeros, either by getting the JET engine to let me use the Replace function or by some other method entirely.</p>
  
  <p>EDIT: Fixed syntax of Replace function. Problem still persists.</p>