You are here

Script snippets

Get file list from st-file

OpenEdge 10.2B

sed -n -e 's/^[ab] \([^ ]*\)/\1/p' -e 's/^d \("[^"]*"[^ ]*\) \([^ ]*\).*/\2/p' < database.st

variation to get the directory names

sed -n -e 's/^[ab] \([^ ]*\)\/[^ ]*.*/\1/p' -e 's/^d \("[^"]*"[^ ]*\) \([^ ]*\)\/[^ ]* .*/\2/p' < database.st | sort -u

Build rename list from incremental df

See pkb: P103489 Title: "Can an incremental df be created without using Create Increment df Utility?"

sed -n 's/RENAME FIELD "\([^"]*\)" OF "\([^"]*\)" TO "\([^"]*\)".*/F,\2,\1,\3/p' incremental.df > renamed_fields.csv