This article is half-done without your Comment! *** Please share your thoughts via Comment ***
I created a new table, and immediately I used this table in a query, but I found the table with a red underline and showing that table is invalid.
The solution is,
SQL Server Management Studio IntelliSence Local Cache:
We should refresh IntelliSense Local Cache so that all newly created objects added in the cache and red underline will disappear.
You can refresh the IntelliSense Local Cache from the edit menu of SSMS.