Check whether the statements used are standard
/*
There are a lot of differences between standard SQL and T-SQL-too much, not here. Also, if you work on SQL Server,
Therefore, using these private extensions is advantageous. Because of the nature of many SQL server features, if you do not use non-standard commands,
There will be many powerful functions that cannot be implemented. If you want to see if your SQL meets the standards, you can use set fips_flagger
Command
*/
Set fips_flagger 'level'
/*
'Level'
Compliance level with FIPS 127-2 will check whether all database operations have reached this level. If the database operation conflicts with the selected ISO standard, Microsoft SQL Server generates a warning.
Level must be one of the following values.
Value description
Entry checks whether it complies with the ISO entry-level standards.
Full
Check whether it complies with ISO full-level standards.
Intermediate checks for compliance with ISO intermediate standards.
Off
Do not check whether the standard is followed.
*/
/*
Set fips_flagger is set during analysis, rather than during execution or runtime. The setting during analysis means that the Set statement takes effect as long as it appears in the batch processing or storage process.CodeWhether the execution actually reaches this point is irrelevant, and the Set statement takes effect before any statement is executed. For example, assume that the Set statement is in if... else statement block, but never reached the statement block during execution, but because of the analysis of if... else statement block, so the set statement still takes effect.
If set fips_flagger is set in the stored procedure, the value of set fips_flagger is restored after the stored procedure returns control. Therefore, the set fips_flagger statement specified in dynamic SQL statements is invalid for any statements after dynamic SQL statements.
*/