Visual Studio 2019 / 2022 intellisense does not work with database project

pault3chpault3ch Posts: 5 New member
I cannot get intellisense to work at all. I open database project in 2019 or 2022 and sql prompt at top. I use sql connect in visual studio to connect to a sql server 2019 and do refresh suggestions and nothing when I type only thing it ever lists is system database tables information. I used to work a few versions back but now useless. tried reinstalling, rebooting, nothing.
Tagged:

Answers

  • Hi @pault3ch

    Can you check your settings for the following options: 
     
    SQL Prompt > Options
     
    Kind regards

    Victoria Wiseman | Redgate Software
    Have you visited our Help Center?
  • pault3chpault3ch Posts: 5 New member
    which ones are you interested in I've checked them all 100 times for a month?

  • pault3chpault3ch Posts: 5 New member
    maybe this will help. If I type a popup comes up but never shows anything about my project and you can see everything disabled but views
     
    I just tried turning linked server off and specifically setting the database to the server localhost / database and db schema, then refreshed suggestions, nothing changed

  • pault3chpault3ch Posts: 5 New member
    here's some log data, changed my database name to DBName for privacy


    2023-03-17 09:50:49.816 -04:00 [Warning] Error occurred while attempting to refresh SSMS intellisense cache
    System.Runtime.InteropServices.COMException (0x80004005): Command "Edit.RefreshLocalCache" is not valid.
       at EnvDTE.DTE.ExecuteCommand(String CommandName, String CommandArgs)
       at RedGate.SqlPrompt.CommonUI.Editor.EditorWindowBase.RefreshCache()
    2023-03-17 09:50:49.819 -04:00 [Information] Populating [(localdb)\ProjectModels].[DBName_Dev] as "Sql2019"
    2023-03-17 09:50:49.819 -04:00 [Information] Chosen server capabilities "Sql2019"
    2023-03-17 09:50:49.999 -04:00 [Information] [(localdb)\ProjectModels].[DBName_Dev] Cache finished with no warnings
    2023-03-17 09:53:51.277 -04:00 [Warning] Error occurred while attempting to refresh SSMS intellisense cache
    System.Runtime.InteropServices.COMException (0x80004005): Command "Edit.RefreshLocalCache" is not valid.
       at EnvDTE.DTE.ExecuteCommand(String CommandName, String CommandArgs)
       at RedGate.SqlPrompt.CommonUI.Editor.EditorWindowBase.RefreshCache()
    2023-03-17 09:53:51.277 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Waiting for master database
    2023-03-17 09:53:51.279 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Connecting...
    2023-03-17 09:53:51.281 -04:00 [Information] Populating [(localdb)\ProjectModels].[DBName_Dev] as "Sql2019"
    2023-03-17 09:53:51.282 -04:00 [Debug] Loading server capabilities
    2023-03-17 09:53:51.282 -04:00 [Debug] Loading schema [DBName_Dev]
    2023-03-17 09:53:51.282 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing schemas...
    2023-03-17 09:53:51.282 -04:00 [Information] Chosen server capabilities "Sql2019"
    2023-03-17 09:53:51.284 -04:00 [Debug]     Time taken for schemas [DBName_Dev] = "00:00:00.0015476" [13 rows]
    2023-03-17 09:53:51.285 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing objects...
    2023-03-17 09:53:51.294 -04:00 [Debug] Loading server logins
    2023-03-17 09:53:51.295 -04:00 [Debug]     Time taken for objects [DBName_Dev] = "00:00:00.0089204" [3 rows]
    2023-03-17 09:53:51.295 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing master objects...
    2023-03-17 09:53:51.297 -04:00 [Debug]     Time taken for master objects [DBName_Dev] = "00:00:00.0019582" [0 rows]
    2023-03-17 09:53:51.298 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing triggers...
    2023-03-17 09:53:51.300 -04:00 [Debug]     Time taken for triggers [DBName_Dev] = "00:00:00.0023063" [0 rows]
    2023-03-17 09:53:51.300 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing data types...
    2023-03-17 09:53:51.305 -04:00 [Debug]     Time taken for data types [DBName_Dev] = "00:00:00.0056088" [35 rows]
    2023-03-17 09:53:51.305 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing ansi data types...
    2023-03-17 09:53:51.307 -04:00 [Debug]     Time taken for ansi data types [DBName_Dev] = "00:00:00.0000112" [0 rows]
    2023-03-17 09:53:51.307 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing columns...
    2023-03-17 09:53:51.319 -04:00 [Debug]     Time taken for columns [DBName_Dev] = "00:00:00.0117111" [1017 rows]
    2023-03-17 09:53:51.319 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing parameters...
    2023-03-17 09:53:51.322 -04:00 [Debug]     Time taken for parameters [DBName_Dev] = "00:00:00.0036323" [0 rows]
    2023-03-17 09:53:51.323 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing indexes...
    2023-03-17 09:53:51.336 -04:00 [Debug]     Time taken for indexes [DBName_Dev] = "00:00:00.0138298" [263 rows]
    2023-03-17 09:53:51.336 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing foreign keys...
    2023-03-17 09:53:51.338 -04:00 [Debug]     Time taken for foreign keys [DBName_Dev] = "00:00:00.0017233" [0 rows]
    2023-03-17 09:53:51.338 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing primary keys...
    2023-03-17 09:53:51.346 -04:00 [Debug]     Time taken for primary keys [DBName_Dev] = "00:00:00.0084756" [0 rows]
    2023-03-17 09:53:51.346 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing services...
    2023-03-17 09:53:51.350 -04:00 [Debug]     Time taken for services [DBName_Dev] = "00:00:00.0031839" [3 rows]
    2023-03-17 09:53:51.350 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing contracts...
    2023-03-17 09:53:51.352 -04:00 [Debug]     Time taken for contracts [DBName_Dev] = "00:00:00.0017675" [6 rows]
    2023-03-17 09:53:51.352 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing message types...
    2023-03-17 09:53:51.355 -04:00 [Debug]     Time taken for message types [DBName_Dev] = "00:00:00.0023582" [14 rows]
    2023-03-17 09:53:51.355 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing routes...
    2023-03-17 09:53:51.356 -04:00 [Debug]     Time taken for routes [DBName_Dev] = "00:00:00.0011960" [1 rows]
    2023-03-17 09:53:51.356 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing xml schema collections...
    2023-03-17 09:53:51.357 -04:00 [Debug]     Time taken for xml schema collections [DBName_Dev] = "00:00:00.0015226" [1 rows]
    2023-03-17 09:53:51.357 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing file groups...
    2023-03-17 09:53:51.360 -04:00 [Debug]     Time taken for file groups [DBName_Dev] = "00:00:00.0024289" [2 rows]
    2023-03-17 09:53:51.360 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing database roles...
    2023-03-17 09:53:51.366 -04:00 [Debug]     Time taken for database roles [DBName_Dev] = "00:00:00.0057503" [9 rows]
    2023-03-17 09:53:51.366 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing server roles...
    2023-03-17 09:53:51.368 -04:00 [Debug]     Time taken for server roles [DBName_Dev] = "00:00:00.0019013" [8 rows]
    2023-03-17 09:53:51.368 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing users...
    2023-03-17 09:53:51.374 -04:00 [Debug]     Time taken for users [DBName_Dev] = "00:00:00.0057107" [4 rows]
    2023-03-17 09:53:51.374 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing default schema...
    2023-03-17 09:53:51.374 -04:00 [Debug]     Time taken for default schema [DBName_Dev] = "00:00:00.0002854" [1 rows]
    2023-03-17 09:53:51.374 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing descriptions...
    2023-03-17 09:53:51.377 -04:00 [Debug]     Time taken for descriptions [DBName_Dev] = "00:00:00.0018362" [0 rows]
    2023-03-17 09:53:51.377 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing partition function...
    2023-03-17 09:53:51.378 -04:00 [Debug]     Time taken for partition function [DBName_Dev] = "00:00:00.0010112" [0 rows]
    2023-03-17 09:53:51.378 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing partition scheme...
    2023-03-17 09:53:51.380 -04:00 [Debug]     Time taken for partition scheme [DBName_Dev] = "00:00:00.0019528" [0 rows]
    2023-03-17 09:53:51.380 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Processing synonyms...
    2023-03-17 09:53:51.385 -04:00 [Debug]     Time taken for synonyms [DBName_Dev] = "00:00:00.0042715" [0 rows]
    2023-03-17 09:53:51.389 -04:00 [Debug] Total time taken [DBName_Dev] = "00:00:00.1069318"
    2023-03-17 09:53:51.389 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Indexing all database columns
    2023-03-17 09:53:51.389 -04:00 [Debug] [(localdb)\ProjectModels].[DBName_Dev] progress: Fetching script information
    2023-03-17 09:53:51.452 -04:00 [Information] [(localdb)\ProjectModels].[DBName_Dev] Cache finished with no warnings
  • Hi pault3ch

    To confirm are you connected to the database in question or just the project?  In Visual Studio we don't load suggestions from the database project, only from databases that have been connected to.
Sign In or Register to comment.