有输入文件1:
C1 C2 C3
5102;22680372 =0000000001
5111;21840112 =0000000002
5363;21980235 =0000000002
5363;22700216 =0000000001
输入文件 2:
5111;21840112 =0000000002
5363;21980235 =0000000001
5363;22700216 =0000000001
预期输出:应按以下方式排序,
JOINKEYS FILES=F1,FIELDS=(1,04,A,6,8,A,16,10,a)
JOINKEYS FILES=F2,FIELDS=(1,04,A,6,8,A,16,10,a)
REFORMAT FIELDS=(F1:1,.. and... )
我需要这个 swquence 的输出文件
File1 C1 File1 C2 file1C3 [file1C3 - file2 C3] value
5102; 22680372 =0000000001 =00000 *(no records in second file for it)
5111; 21840112 =0000000002 =00000 *(1-1 =0)
5363; 21980235 =0000000002 =00001 *(2-1= 1)
5363; 22700216 =0000000001 =00000 *(1-1 =0)
只是为了解释你现在正在尝试这个
选项 COPY
JOINKEYS F1=INA,FIELDS=(1,4,A,6,8,A)
JOINKEYS F2=INB,FIELDS=(1,4,A,6,8,A)
REFORMAT FIELDS=(F1:1, 25,F2:16,10)
INREC BUILD=(1,25,26,10,SFF,SUB,36,10,SFF,EDIT=(STTTTTT))
结果:
5060;22222222 =0000000001 (blank) i just need 0001 - nothin(0) = 1 simply 1 here
5102;22680372 =0000000001;000000000
5105;22222222 =0000000002 (blank) need 2 here same 2-0 or nothing(unmatched) = 2