[Use regular expression]
I want to review the table creation script (DDL) of the database to the DBA. First, it is generated to a new query window. Then, it is necessary to clear many useless items such as "go" in the automatically generated text, but also remove the line break, it is like the following script:
Exec sys. sp_addextendedproperty @ name = n' MS _ description', @ value = n' wave id', @ level0type = n' schema ', @ level0name = n' dbo ', @ level1type = n' table ', @ level1name = n' basemonitorbatch', @ level2type = n' column', @ level2name = n' batchid'
Go
Exec sys. sp_addextendedproperty @ name = n'ms _ description', @ value = n'boundary encoding ', @ level0type = n'scheme', @ level0name = n'dbo ', @ level1type = n' table ', @ level1name = n' basemonitorbatch', @ level2type = n' column', @ level2name = n' batchcode'
Go
In this case, we need to use a regular expression. Paste a picture. You can see it at a Glance:
With this method, you can also clear "set ansi_padding off \ NGO" and so on:
[Use wildcards]
Because ibatis is used, to extract the SQL definition segments, you can change your mind and replace them with wildcards, remove the label similar to <select id = "getsendpaycount2" resultclass = "int">:
[Summary]
The above method saves a lot of time and improves your work efficiency. Similar functions are available in Visual Studio.