Parsing a fixed format text file & upload into DB

Question:
I want to update an Oracle database daily, with a fixed format text file passed by another product. The text file contains fixed format data with each record separated by a carriage return and line feed. Is it possible to accomplish this in PowerBuilder?

Answer:
You do not mention the format of the columns for the input file, but if the file is tab delimited or comma delimited, then you can use the importfile or importstring function of PowerBuilder to inport your data into a DataWindow, then use the update command to load the data into your Oracle database. This is both a quick and efficient manner to load the data into Oracle.

If the data is not in a PowerBuilder recogniseable format, then you could write a custom script to perform the process, but my preference in this would be to use SQL Loader, an Oracle tool, to bulk import the data.

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

Recent Articles: