SORTING CELLS WITH NUMBERS, NUMBERS WITH DASHES, NUMBERS WITH TEXT

Copper Contributor

IM TRYING TO DO INVENTORY HERE AT WORK. HARLEY DAVIDSON SOME YEARS AGO CONVERTED THERE PART NUMBERING SYSTEM FOR ALL NEW PARTS FOR YEARS IT HAD BEEN, 5 DIGITS A DASH FOLLOWED BY 2 DIGITS (YEAR OF INTRODUCTION) AND SOMETIMES FOLLOWED BY A LETTER IF THERE WAS A SUPERCESSION e.g. 12345-67A. NEW PARTS NUMBERS ARE 8 DIGIT 12345678. ...I NEED THIS...WHAT HAS TO BE DONE?


NUMBZ.jpg

1 Reply

@CARLOS_SFHD 

Hi,

How about this way?

 

original data

门牌号

10A

100A

25A

 

result

 

门牌号  

10A 
25A 
100A 

Screenshot_2023-06-23-08-59-50-425_cn.uujian.browser.jpg

 

select * from 按门牌号自然排序 order by 门牌号 COLLATE NATURAL_CMP;

 

http://e.anyoupin.cn/EData/?p=Tools/detail&r=177