This topic is locked

Delimited Fields

11/4/2008 1:54:43 PM
PHPRunner General questions
D
davesmith author

I'm still getting the feel for PHP Runner, and had a question. In some databases I've used in it is common to delimit certain data within a field and then to use that data to link elsewhere. For example, you might have a field which stored the names of people who had purchased a product and you might store it as:
Bob|Bill|Ted|Jim
You'd then use those values to either display the text, html or whatnot. I'm still getting the hang of the scripting language, so figured before I beat my head on the wall too much I would just ask. Is there any easy way to read in those values and seperate them?

A
alang 11/4/2008

The PHP "explode" function is useful for this - creates an array of strings from a single string where you can specify the delimiter character.

D
davesmith author 11/5/2008

The PHP "explode" function is useful for this - creates an array of strings from a single string where you can specify the delimiter character.


Okay thanks a bunch, will read up on it.