| 
			
			 | 
		#1 | 
| 
			
			
			
			 Junior Member 
			
			![]() Posts: 2 
				Karma: 10 
				Join Date: Nov 2013 
				
				
				
				Device: Pocketbook touch lux 
				
				
				 | 
	
	
	
		
		
			
			 
				
				Regular Expressions Help
			 
			
			
			Hi everyone, 
		
	
		
		
		
		
		
		
		
		
		
		
	
	most of my ebooks are sorted using the following structure: author, series seriesnumber, title. While importing these books into calibre, i use following regular expression: (?P<author>((?!\s-\s).)*)\s-(?:\s(?P<series>((?!\s-\s).)*)\s-)?(?:\s(?P<series_index>((?!\s-\s).)*)\s-)?\s(?P<title>.*) Now it will sort author, series and title automatically. Only the series_index will not display properly. Where is the fault in the expression setting?  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| 
			
			 | 
		#2 | 
| 
			
			
			
			 Junior Member 
			
			![]() Posts: 2 
				Karma: 10 
				Join Date: Nov 2013 
				
				
				
				Device: Pocketbook touch lux 
				
				
				 | 
	
	
	
		
		
		
		
		 
			
			Solution found, thread can be closed. 
		
	
		
		
		
		
		
		
		
		
		
		
	
	(?P<author>[^_-]+) -?\s*(\[|\()?\s*(?P<series>[^_0-9\[\(-]*)(?P<series_index>[0-9.]*)\s*(\]|\))?\s*-\s*(?P<title>[^_\[\(]+)\s*  | 
| 
		 | 
	
	
	
		
		
		
		
			 
		
		
		
		
		
		
		
			
		
		
		
	 | 
| Advert | |
| 
         | 
    
![]()  | 
            
        
    
            
  | 
    
			 
			Similar Threads
		 | 
	||||
| Thread | Thread Starter | Forum | Replies | Last Post | 
| Regular Expressions help | deamonfruba | Library Management | 2 | 06-02-2012 03:09 AM | 
| Help with regular expressions | MostlyCarbon | Library Management | 0 | 02-04-2012 04:00 PM | 
| Regular Expressions | geormes | Calibre | 4 | 08-04-2011 08:09 AM | 
| Another help with regular expressions | encapuchado | Library Management | 6 | 06-21-2011 04:14 PM | 
| Help with Regular Expressions | ghostyjack | Workshop | 2 | 01-08-2010 12:04 PM |