Re: [SQL] Funtion to clean up strings?

2009-02-18 Thread Gregory Stark
Andreas writes: > Hi > Thanks, that really works :) > > Now a last extension. > Some numbers were entered in a "110% perfect" way with an excessive (0). +49 > (0) 123 / 456 789 > I have to suspect the source liked to express that it's either +49 or 0 if > the +49 isn't applicable, but not bo

Re: [SQL] How concat 3 strings if 2 are not empty?

2009-02-18 Thread Andreas
No. B should only appear if A and C are not empty. B is just a filler. Thanks Andreas A. Kretschmer schrieb: In response to Andreas : I'd like a function that concats 3 string parameters on condition the 1st and 3rd are NOT empty or NULL. xCat (s1, s2, s3) s2 would be a connector that appe

Re: [SQL] How concat 3 strings if 2 are not empty?

2009-02-18 Thread A. Kretschmer
In response to Andreas : > Hi, > > I'd like a function that concats 3 string parameters on condition the > 1st and 3rd are NOT empty or NULL. > xCat (s1, s2, s3) > s2 would be a connector that appears only if s1 and s3 are set. > > NULL and an empty string '' should be handled the same. > > e.g

[SQL] How concat 3 strings if 2 are not empty?

2009-02-18 Thread Andreas
Hi, I'd like a function that concats 3 string parameters on condition the 1st and 3rd are NOT empty or NULL. xCat (s1, s2, s3) s2 would be a connector that appears only if s1 and s3 are set. NULL and an empty string '' should be handled the same. e.g. 'PostgreSQL', ' is ', ' great'-->