Home > database >  Extraction of Chinese characters and Numbers
Extraction of Chinese characters and Numbers

Time:09-21

Separate extraction of Chinese characters and Numbers, I will, but in the actual work, is quite complicated,
I need to reach the effect is:





The original data is as follows:
 - Table structure for Sheet1 
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
IF the EXISTS (SELECT * FROM sys. All_objects WHERE object_id=object_id (N '[dbo]. [Sheet1]) AND type IN (' U'))
DROP TABLE [dbo] [Sheet1]
GO

The CREATE TABLE [dbo] [Sheet1] (
[instructor] nvarchar (255) COLLATE Chinese_PRC_CI_AS NULL
)
GO



-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
- Records of Sheet1
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
INSERT INTO [dbo] [Sheet1] ([instructor]) VALUES (N 'supervisor [112017], guang-jun li [112123]')
GO

INSERT INTO [dbo] [Sheet1] ([instructor]) VALUES (N 'Han Xiang [004041] 2)
GO

INSERT INTO [dbo] [Sheet1] ([instructor]) VALUES (N 'Mr Zhang [334104], tintin [334137], Derek kwok [334125], Zhao Hong [334110], Yang count [334101], min-min wang [334112], Danny [334138]')
GO

INSERT INTO [dbo] [Sheet1] ([instructor]) VALUES (N 'Mr Zhang [334104], tintin [334137], Derek kwok [334125], juan-juan zheng [334108]')
GO

  • Related