Question

3
Replies
4985
Views
Close popover
Cloe Walker (CloeW938)
IT Solution Service

IT Solution Service
SG
CloeW938 Member since 2018 158 posts
IT Solution Service
Posted: August 5, 2018
Last activity: August 6, 2018
Closed

How to parse CSV into page list

Hi,

We need to take in CSV file (see below), and create a work. One CSV file becomes a single work object, and I want to make a page list from a number of multiple lines inside a CSV file. For example, CSV looks something like this:

ProductID, ProductName, Price
004, Eraser, 1.5
010, Pen, 1.2
002, Note, 2.0
050, Pencil, 0.5

File Listener finds this file and start an activity pyStartCase under MyCo-MyApp-Work-PurchaseRequest class. I konw how to create a file service and service package using a Service Wizard.

What I do not know is, how to parse CSV into Page List. I searched PDN and found some related articles like below but not quite.
https://community.pega.com/knowledgebase/articles/how-parse-comma-separated-values-csv-file-using-file-service

I believe I need to use Parse Delimited rule and Parse XML rule but I am not sure how. What is the simplest and easiest way to achieve this? Could someone describe the detail?

Thanks,

Data Integration
Moderation Team has archived post,
Close popover This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.