Search code examples
mysqlsqldatabaseviewssms

table i created is not showing in SSMS even after refreshing


i saved a table in my SSMS database but its not showing even after i refresh it. any idea what should be done??


Solution

  • Try reconnect and asure yourself that you are creating table rather than temporary table which disapear after closing or interupting session.

    1. When reconnect will help. It means that table was created but only view of it wasn't available yet.
    2. Data from temporary table begin name with # sign. To check if you using temporary table you can perform code shown below:
        if object_id('tempdb..#yourtablename') is null 
            PRINT N'Temporary table is not created';
        if object_id('tempdb..#yourtablename') is not null 
            PRINT N'Temporary table is created';
        if object_id('dbo.yourtablename') is null
            PRINT N'Normal table is not created';
        if object_id('dbo.yourtablename') is not null 
            PRINT N'Normal table is created';     
    

    Make sure that you are in the database where you previously created the table