Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi below is my example data,
| DEPT | ||
| IT Dept | CSE Dept | ECE DEPT |
| XXXX1 | XXXX1 | XXXX1 |
| XXXX2 | XXXX2 | XXXX2 |
| XXXX3 | XXXX | XXXX3 |
| XXXX4 | XXXX4 | XXXX4 |
| XXXX5 | XXXX5 | XXXX5 |
I want the IT dept data to be clubbed with IT Dept,CSE dept data to be clubbed with CSE Dept,ECE dept data to be clubbed with ECE Dept.
all these three dept(IT,CSE,ECE) data to be clubbed as one field under "DEPT".
please help me on how to do it in load script.
Do you mean "merged"?
yes
Hi Mano
try this in the script
[IT DEPT] & ' - ' & [CSE Dept] & ' - ' & [ECE DEPT] as DEPT
/Teis
I think you can use a crosstable load, if I understood you correctly: (see also attached)
DEPT:
Load * Inline [IT_Dept,CSE_Dept,ECE_DEPT
XXXX1,XXXX1,XXXX1
XXXX2,XXXX2,XXXX2
XXXX3,XXXX,XXXX3
XXXX4,XXXX4,XXXX4
XXXX5,XXXX5,XXXX5
];
CrossTable(DEPT_Type, DEPT,1) load
RecNo() as ID,
IT_Dept as IT_Dept,
CSE_Dept as CSE_Dept,
ECE_DEPT as ECE_DEPT
resident DEPT;
t1:
load * inline
[
IT Dept, CSE Dept, ECE DEPT
XXXX1 ,XXXX1, XXXX1
XXXX2 ,XXXX2 ,XXXX2
XXXX3 ,XXXX ,XXXX3
XXXX4 ,XXXX4 ,XXXX4
XXXX5 ,XXXX5 ,XXXX5
]
;
t2:
load
[IT Dept] &[CSE Dept]&[ECE DEPT] as DEPT
Resident t1;
drop table t1

Has this answered your question? If so, can you please close this thread by marking one of the answers correct? It will help others find a (correct) answer to similar problems and lets other contributing members know that this requires no more attention.