Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 Sra1bandi
		
			Sra1bandi
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Table 1:-
id status1
1 Error
2 completed
3 Errore
4 Cancelled
Table 2:-
id status2
1 Cancelled
2 completed
3 Cancelled
4 completed
This is already developed app by someone now we got new requirement i.e,
When the Status1 from table1 shows===> "Error" in table2==> status2 also need to show as==> "Error". Id is the common field for both tables so many fields are there in two tables but Id is primary key and status field needs to change as above mentioned.
both are different tables not joined in backend how i need to show Status2 as Error when status1 shows Error
Regards,
Sra1.
 BrunPierre
		
			BrunPierre
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Table1:
Mapping LOAD * Inline[
ID,STATUS1
1,Error
2,Completed
3,Error
4,Cancelled ]
Where Match(STATUS1,'Error');
Table2:
LOAD *,
ApplyMap('Table1',ID,STATUS2) as STATUS
Inline[
ID,STATUS2
1,Cancelled
2,Completed
3,Cancelled
4,Completed ];
DROP Field STATUS2;
RENAME Field STATUS to STATUS2;
EXIT SCRIPT;
 Sra1bandi
		
			Sra1bandi
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		There are so many ID's which are errors not single id
 BrunPierre
		
			BrunPierre
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi @Sra1bandi
Try again with the above modified script. Values of Status2 are retained when there is no match.
