Need a simple file based utilty for shell scripts

Hello,

I'm wondering if you may know of a simple file based UNIX utility that can be used to store and retrieve values on a flat file, let's say i have a file called "kru", i'd like to be able to specify a request like:
while(....)
if [ kru.fld1 = $stepid ] ; then
kru.fld2 = $rec_cnt
kru.fld3 = $status_code
krul.fld4 = $file_status
fi
done

Basically i'm trying to avoid using Oracle to manage the step by step audit values for a bunch of kshells used to automate the manual load processes for an Oracle database.

Thanks very much for any inisghts! :rolleyes:
BobK

Please make your question more clear

esham
www.openhat.org

Hi Esham,

Well seems to me that there must be a pretty straight forward string based utility that could be used as a flat file database to keep track of condition codes, record counts ect for the various steps in a script.

For example let's say step1 of my oracle build script is to check the record counts of a table. I would retrieve the count and then store it by using somehting like this: file_db.step="step1", file_db.recnt=$oracnt ect.

Before loading oracle in step2 i would first check to make sure that the file_db.recnt from step1 was 0, ie:

if [ file_db.step = "step1" && file_db.recnt = 0 ] ; then
ksh load_table.ksh
else
file_db.step =j "step2"
file_db.status=1
fi

In other words, it would like like a C structure, but wrapped by some easy to use interface.

Thanks for any idea Esham!
BobK

Hi.

Using Google search for flat file database linux utility shell returns about 500K hits.

This may not be simple, but it looks interesting: http://ff-extractor.sourceforge.net/ ... cheers, drl

Thanks drl, that does looking interesting, going to check it out further!

Have a goodone drl!

BobK