Is there any way to get fields from column delimited by some delimeter
Posted in 2006
Topics: Server Administration
have a string for eg: "12|A|B", and need a function that takes "|" as
field delimeter and returns 2nd or say 3rd column. Is it possible to do
this in informix. For Eg: If I ask for 2nd column I get "A".
Also, is there a way to find a position of character in a string. For
Eg: "ABCD" - C's position is 3.
---
About how I am executing SQL:
I am not really a pro in informix, what I can tell is that I invoke
dbaccess and type SQL in there to execute it. I think it's informix
dynamic server (IDS) because I could use MULTISET which is part of IDS.
Please let me know how do I find out if you need to know. I think
Informix version is 9 40 FC7 (if this makes sense).
--
Install the regexp datablade, then it's a piece of cake
http://www.oninit.com/article/newstracker.php?id=19
Paul Watson
Tel: +44 1414161772
Mob: +44 7818003457
Web: www.oninit.com
GO FURTHER with DB2
GET THERE FASTER with Informix.
Attend the IDUG 2006 European Conference.
Vienna, Austria. 2-6 October 2006
Visit http://www.iiug.org/conf for more information.
> -----Original Message-----
> From: mohitanchlia@gmail.com [mailto:mohitanchlia@gmail.com]
> Posted At: 13 September 2006 19:05
> Posted To: comp.databases.informix
> Conversation: Is there any way to get fields from column
> delimited by some delimeter
> Subject: Is there any way to get fields from column delimited
> by some delimeter
>
>
> have a string for eg: "12|A|B", and need a function that
> takes "|" as field delimeter and returns 2nd or say 3rd
> column. Is it possible to do
>
> this in informix. For Eg: If I ask for 2nd column I get "A".
>
> Also, is there a way to find a position of character in a string. For
> Eg: "ABCD" - C's position is 3.
>
> ---
> About how I am executing SQL:
> I am not really a pro in informix, what I can tell is that I
> invoke dbaccess and type SQL in there to execute it. I think
> it's informix dynamic server (IDS) because I could use
> MULTISET which is part of IDS.
>
> Please let me know how do I find out if you need to know. I
> think Informix version is 9 40 FC7 (if this makes sense).
> --
>