📜  检查 sql 临时表是否存在 - SQL 代码示例

📅  最后修改于: 2022-03-11 15:05:02.741000             🧑  作者: Mango

代码示例2
IF OBJECT_ID('tempdb..#Results') IS NOT NULL
    Truncate TABLE #Results
else
    CREATE TABLE #Results
    (
        Company             CHAR(3),
        StepId              TINYINT,
        FieldId             TINYINT,
    )