hi champs,
i have created dynamic insert statements , but sed throwing me an error if i do have a blank character inside it.....
my actual string
HTML Code:
insert_config="INSERT INTO CBF_XXXX ( CS_ID, CS_NAME, FIELD_SEP, REC_SEP, FIELDS_NUM, FTPS_FILE, \
> DECSN_FMT_TYPE, DECSN_FIELDS, DECSN_SCHDL_TYPE, DECSN_SCHDL, DECSN_TIME, \
> DECSN_UNITWS, UNIQ_FILE_CONVNS, OUTBOX_RETN, UPDATE_TIME ) VALUES action_list ;"
my dynamic o/p
HTML Code:
echo ${insert_config_str}
('CSPAT191','CSXXXO,NENINETYONENL','|','" "','15','Y','ALL','NULL','DAILY','NULL','13:00','N','N','1',SYSDATE)
but while using the follwoing sed
HTML Code:
insert_config_act=`echo $insert_config | sed -e 's/action_list/'${insert_config_str}'/g' `
i am facing
"sed: -e expression #1, char 54: unterminated `s' command"
but not able to trace out.......why ???
if in the insert_config_str if i am going to fill some value at 4th position, hen sed working fine...but here
4th column in blank,, it's throwing me error....
but i need to insert the blank character in that column.....can any one help me out to figure out the problem ????