Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

How to write to a text file using Siebel workflow

Posted on 2009-05-12
5
Medium Priority
?
7,262 Views
Last Modified: 2012-05-06
Hi All,

I need to extract some values from a .txt file for example
1234,5678,1234
These values are stored ina text file. Then i need to see if there are any duplicate numbers.
In the example it means that 1234 is a duplicate.
I know this is possible using server script in siebel but is there any way i can use Siebel workflow to perform this?

Also at the end i also need to write to file that for example "1234 is a duplicate".
Does Siebel workflow has this functionality (to do IO operations on txt file)?
I am using Siebel Tools 8.0.

Thanks.
0
Comment
Question by:talltk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 2

Expert Comment

by:srihariramadas
ID: 24372032
There are Vanilla Siebel Business Services that can be used to read .csv and .xml files. The same Business Service can be used to write into a file too.
If you are using Integration Objects you will want to use "EAI XML Read from File" and "EAI XML Write to File". For pure flat files there are Business Services like "Read CSV File"
Thanks
Srihari Ramadas
0
 

Author Comment

by:talltk
ID: 24372141
Hi SriHari Ramadas,

Nope i am not using Integration Objects. So which Business Service should i use? I just need to read a file and write to a file in Siebel Workflows?

You mention that there are "Vanilla Siebel Business Services can be used to write into a file too". Does it write to a .txt file? Because from what i read and ask around they say that it can only be use for .csv or .xml.

I am quite new in Siebel and would appreciate it if you could elaborate more or point me to the direction where reading and writing to a .txt file could be done using workflows.

Thank you
0
 
LVL 2

Accepted Solution

by:
srihariramadas earned 1500 total points
ID: 24373863
Hi,
I don't think Siebel will be able to read a .txt file. Reason being, Siebel either needs a predefined hierarchy (possible from xml when using Integration Objects) or  it  should know number of property sets it should define for assigning file values. In your case, you can have each of the values as different rows in csv, assign these to a property set single row at a time. You can have another property set for comparison.
You should get the .txt converted to a .csv file and feed it to the workflow.
On Vanilla BS, "Read CSV File" BS has the following methods - "CsvToPropSet" and "PropSetToXml". The former will do the trick for you. On writing back, try using "EAI XML Write to File" BS with the method "WritePropSet". You need to provide the file path here.
FYI - Clib.getcwd() method in server script will return you the current working folder (always BIN folder in Siebel)
Thanks
Srihari Ramadas
0
 

Author Closing Comment

by:talltk
ID: 31580864
Thanks Srihari Ramadas.
You mention that i need to convert ".txt converted to a .csv file and feed it to the workflow". In Siebel can we do that? Is there any way or how do we do that in server scripts or workflows in siebel?
0
 
LVL 2

Expert Comment

by:srihariramadas
ID: 24381882
Siebel doesnt have the capability of converting .txt to .csv. Manually this can be done by opening the .txt file in Excel and use "Save As" option to store it in .csv format. I have seen projects using Java application to do the same conversion.
0

Featured Post

Learn how to optimize MySQL for your business need

With the increasing importance of apps & networks in both business & personal interconnections, perfor. has become one of the key metrics of successful communication. This ebook is a hands-on business-case-driven guide to understanding MySQL query parameter tuning & database perf

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lotus Notes has been used since a very long time as an e-mail client and is very popular because of it's unmatched security. In this article we are going to learn about  RRV Bucket corruption and understand various methods to Fix "RRV Bucket Corrupt…
Instead of error trapping or hard-coding for non-updateable fields when using QODBC, let VBA automatically disable them when forms open. This way, users can view but not change the data. Part 1 explained how to use schema tables to do this. Part 2 h…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question