Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 bobbydave
		
			bobbydave
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		So I have files that I take in the following
The file name is Date_Area_Service.xlsx
E.g.
042016_Breach_AST
042016_Breach_ADS
042016_Breach_Mgmt_Info
042016_Breach_IT_Ops
I can get the Date and Area and to get the Service part of the filename, I use FileBaseName()
SubField(FileBaseName(), '_', -1)
which is all well and good if it is AST or ADS but when I have to get Mgmt_Info, I will only get Info and IT_Ops will only give me Ops.
Anyone know how I would get
ADS
AST
Mgmt_Info
IT_Ops
Thanks
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		May be this:
Mid(FileBaseName(), Index(FileBaseName(), '_', 2) + 1) as FieldName
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		May be this:
Mid(FileBaseName(), Index(FileBaseName(), '_', 2) + 1) as FieldName
 bobbydave
		
			bobbydave
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Saving the world as usual, Sunny!
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hahahaha, I am glad I was able to help 
