Need to divide data in groups
Posted: Sun Apr 10, 2011 5:46 am
Hi All,
I need your help to implement a logic:
I am having source data like this
Col1 Col2 Col3 Col4
ABC/001 E0101 ABC/001 E4031
ABC/001 E0101 ABC/001 E15399
ABC/001 E0101 ABC/001 E022
ABC/001 E1360 ABC/001 E0101
ABC/001 E4031 ABC/001 E022
ABC/001 E5941 ABC/001 E623
ABC/001 E5941 ABC/001 E0101
ABC/001 E5941 ABC/001 E022
ABC/001 E7539 ABC/001 E022
ABC/001 E186 ABC/001 E4031
I want to update Col3 in such a way so that no inter-patching will be there. I don't want to update all values in col3. I want min updates in col3. as of now these records represents links between col2 and col3 for same building ABC/001 I want to create minimum no of new buildings so that there is no link between same building.
Please provide your inputs. This will help me.
Regards,
Prashant
I need your help to implement a logic:
I am having source data like this
Col1 Col2 Col3 Col4
ABC/001 E0101 ABC/001 E4031
ABC/001 E0101 ABC/001 E15399
ABC/001 E0101 ABC/001 E022
ABC/001 E1360 ABC/001 E0101
ABC/001 E4031 ABC/001 E022
ABC/001 E5941 ABC/001 E623
ABC/001 E5941 ABC/001 E0101
ABC/001 E5941 ABC/001 E022
ABC/001 E7539 ABC/001 E022
ABC/001 E186 ABC/001 E4031
I want to update Col3 in such a way so that no inter-patching will be there. I don't want to update all values in col3. I want min updates in col3. as of now these records represents links between col2 and col3 for same building ABC/001 I want to create minimum no of new buildings so that there is no link between same building.
Please provide your inputs. This will help me.
Regards,
Prashant