Login | Register   
RSS Feed
Download our iPhone app
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.

Tip of the Day
Language: PowerBuilder
Expertise: Beginner
Apr 23, 1997



Application Security Testing: An Integral Part of DevOps

How to separate data from an input using the FILEREAD statement

I would like to know how to separate data from an input using the FILEREAD statement.

The data retrieved from the FILEREAD is comma-separated, and I would like to extract this information into different variables.

For example:

Data extracted: Guy, Osborne, Quebec, Canada

From this I would like to extract:

  • Guy into a variable
  • Osborne into a variable
  • Quebec into a variable
  • Canada into a variable

You can use the PFC service pfc_n_cst_string function of_parsetoarray()to parse delimited strings into an array of strings, which would be better than named variables. Then, if you want to put the data into named variables, simply copy the array element you wish to use.

DevX Pro
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.
Thanks for your registration, follow us on our social networks to keep up-to-date