Monday, December 8, 2008

Shell Script to serach for file whether present or not

Hi all,

the below shell script is used to identify if the source file is present or not and depending upon the command can be used in the command task of informatica.

This script is basically used for searching a file and then running the entire workflow.
this is basically for Bourne shell

# /usr/bin/sh
if test -s "path/Filename.lst"
then exit 0;
else exit 1; fi

and

cat commands

for example there are two files file1 and file2
and you wantto write to write it to file 3 teh entire content then

cat file1 > file3
cat file2>>file3

>> indicates it does not append the earlier data

No comments: