Subject | Re: [Firebird-Architect] Substring |
---|---|
Author | Ann W. Harrison |
Post date | 2004-10-14T22:13:53Z |
Hi Arno,
It's an error to supply a negative length or a start that
comes after the end of the string, but otherwise, anything
goes. What a useful construct.
Cheers,
Ann
>The end-position (E) is S+L, thus your examplesThat agrees with what I understood from the SQL-92 document.
>
> > substring ('abcdefghij' from 1 for 5) => 'abcde'
> > substring ('abcdefghij' from 0 for 5) => 'abcd'
> > substring ('abcdefghij' from -1 for 5) => 'abc'
>
>are right.
It's an error to supply a negative length or a start that
comes after the end of the string, but otherwise, anything
goes. What a useful construct.
Cheers,
Ann