Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
Hey ppl,
In one of a qvd i have column with values like,
| ABCD-0070085158 | 
| BSCD-0070085178 | 
| JKRF-0070085153 | 
| QOPD-0070085238 | 
I want to display the values like ,
| 70085158 | 
| 70085178 | 
| 70085153 | 
| 70085238 | 
I tried SubField(ID,'0') as NewID in the script , but it doesn't work
I tried the same by simply loading the data like Load ID as OldID and used SubField(OldID,'0') in the expression in the Pivot Straight table, but no luck 
I think this is because, there are multiple zeros in between the data. How do I display as desired ? Any other substring kind of functions will help or any workaround solution?
TIA,
James
 MindaugasBacius
		
			MindaugasBacius
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		What is the question here my friend?
 
					
				
		
Sorry Sunny ,
Some keyboard shortcut posted the query automatically while i was composing ... Now I edited the post...
-James
 MindaugasBacius
		
			MindaugasBacius
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		If you are willing to split the field try using:
SubField(Field_name, '-') as First_param,
SubField(Field_name, '-', 2) as Second_param
Read more:
I suggest you to bookmark this page 
 
					
				
		
 puttemans
		
			puttemans
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		try right(subfield(ID,'-', 2), 😎
 
					
				
		
 florentina_doga
		
			florentina_doga
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		use
=num(subfield('ABCD-0070085158','-',-1))
 MindaugasBacius
		
			MindaugasBacius
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		This option then:
=SubField('ABCD-0070085158','-00',2)
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		How about this:
SubField(ID,'-', 2) * 1 as NewField
 
					
				
		
 jonathandienst
		
			jonathandienst
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try
=Replace(LTrim(Replace(SubField(ID, '-', 2), '0', ' ')), ' ', '0')
 
					
				
		
instead of subfield you may use (if the values are in above Format)
num(Keepchar(ID,'0123456789','#0')
