sql statement string manipulation

I encountered a problem when finishing an exam data, inconsistent data layout template to the school and the data stored in the database column. Professional classes in the database and write together, and professional templates and classes are separate, if a professional a professional change, then not only inefficient, but accuracy can not be guaranteed, so I think the string operations in sql.

Original results shown in Figure:

Since the values ​​have a feature class in: The last two are classes, which can save a lot of manpower. After the class can be listed in two split out as a separate, so the problem is solved. I see the operation:

 

When writing these codes I encountered two problems:

1, the inner and outer connecting any difference, respectively, for use when

2, the operation of the query results, such as cutting the string, operations, etc., on the sql statement in the implementation of high efficiency or on the high code efficiency

Welcome to leave a message for me disambiguation

 

Published 233 original articles · won praise 22 · views 10000 +

Guess you like

Origin blog.csdn.net/qq_41026669/article/details/103942935