The two most common ways to deal with this are:
- To import data as in a step, move what you need into your βrealβ tables, then truncate the intermediate table.
- Use a text utility to cut just what you need.
My text selection utility is awk. The minimal awk script - which probably won't work for you without any tweaking - will look like this.
$ awk 'BEGIN { FS="^";OFS=",";}{print $2, $4}' test.dat first column entry,this would be the 3rd column
What is the setting? This usually includes care of the embedded commas, single quotes, and double quotes.
This part
BEGIN { FS="^";OFS=",";}{print $2, $4}
is the whole awk program.
awk.
source share