How to store records from database into a Flat File or a string in flat file format in webMethods?

How to store records from database into a Flat File or a string in flat file format in webMethods?

I assume by “webMethods” you mean Integration Server. (There are multiple products under the webMethods name. Which of them you’re using will vary the helpful answer.)

Read the data from the database.
Write the data to a file.

:slight_smile:

Use the JDBC adapter to read from the DB.

Use the flat file services and structures to define a flat file schema that can easily create records formatted with proper delimiters and escaping. The flat file docs have all of the details.

I am using Software AG Designer 10.7 as a Integration Development Environment.

I used a select adapter service eat the start of the flow service to fetch the data from the database and after that used a loop to read go through all the records. In the loop, I invoked flatFile:vconvertToString service to store the data in a string of service out. I mapped the output doc of adapter service to ffValues and provided the delimiters, flat file schema. But when I am executing the service, the string is null. I don’t why what went wrong, why the records are not storing the string.

It would really be helpful if you can resolve this issue. Thank You in advance : )

If you can share a screen shot of the FLOW steps (without exposing sensitive/private info) that would be helpful for troubleshooting. Or if you can post the package here, if it is a small example, someone here can desk-check the steps.

You can step through your services with the debugger to see if there is anything that may provide you with info as to what may be amiss.

Uploading: service.PNG…

Pipeline:

When I am debugging the service, the values are not going into the string.

service

Can you share the ffSchema too?

ffSchema:

image

And I have given the delimiter input in service In of convertToString built-in service as \n , similar to the ffSchema which was defined.

The records should be: id,name,age
1, Andrew, 22
2, Sam, 21… etc

Sorry that my request for additional info was too specific. Can you share record definition too – everything that you have set up to create the flat format string. And the complete service defined to read and write the data.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.