Options

Suggestions Stopped Working After Upgrade to Version 10.14.12.7945

AshleeAshlee Posts: 5 Bronze 1
edited April 3, 2024 6:15PM in SQL Prompt
I upgraded SQL Prompt to Version 10.14.12.7945 yesterday and no longer get suggestions or some auto-formatting features in SSMS v18.12.1. I do not use SQL Prompt anywhere else, so I cannot confirm if this is limited to SSMS.

Features NOT Working:
  • No suggestions displayed when typing an object name.
  • Schema name is not automatically inserted when typing an object name.
  • Schema name is not inserted when running Format SQL or Qualify Object Names.
  • Pressing tab after * no longer expands the wildcard to display field names.
  • Running Expand Wildcards does not work either.

Features Still Working:
  • Built-in shortcuts appear to be working. For example, typing 'ssf' does expand to 'SELECT * FROM'.
  • Apply Casing Options is working as expected.
  • Insert Semicolons is working as expected.
  • Remove Square Brackets is working as expected.

Tried disabling and reenabling SQL Prompt > Enable Suggestions. Also tried Refresh Suggestions, no change. Also tried rebooting my machine but that hasn't made a difference.

UPDATE: Noted the error below in the logs following the update. The log file includes the actual correct server name. Replacing the server name with placeholder <servername> in this post. 

2024-04-03 08:46:23.782 -05:00 [Information] Created new ServerCandidate for server: <servername>
2024-04-03 08:46:53.519 -05:00 [Warning] Failed to load server <servername>
Microsoft.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: HTTP Provider, error: 0 - )

No other logs mention "Created new ServerCandidate" but they do include a similar error, indicating a connection problem.

2024-04-02 15:26:12.397 -05:00 [Error] Error checking for platform availability
System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

Is there a way to manually correct the ServerCandidate connection settings? I'm not seeing any obviously related settings in the SQL Prompt menu or options.

Best Answer

  • Options
    AshleeAshlee Posts: 5 Bronze 1
    I was able to resolve this issue by downloading the installer directly from my license management page, uninstalling SQL Prompt, then reinstalling using the downloaded installer.

Answers

  • Options
    AshleeAshlee Posts: 5 Bronze 1
    Sharing more info, I enabled verbose logging and noted an error when launching SSMS. Here are the last 5 entries in the log after opening SSMS and connecting to my locally-hosted dev database:
    <div>2024-04-03 12:55:01.249 -05:00 [Verbose] Check for updates: Update results received: End of update results.</div><div>2024-04-03 12:55:01.251 -05:00 [Verbose] Check for updates: State: UpToDate</div><div>2024-04-03 12:55:01.253 -05:00 [Verbose] Check for updates: Exiting check for updates</div><div>2024-04-03 12:55:18.106 -05:00 [Information] Sql History initialized successfully</div><div>2024-04-03 12:55:21.240 -05:00 [Error] Error checking for platform availability</div><div>System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 20.90.200.114:443</div><div>&nbsp; &nbsp;at System.Net.Sockets.Socket.InternalEndConnect(IAsyncResult asyncResult)</div><div>&nbsp; &nbsp;at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)</div><div>&nbsp; &nbsp;at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception)</div><div>&nbsp; &nbsp;--- End of inner exception stack trace ---</div><div>&nbsp; &nbsp;at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)</div><div>&nbsp; &nbsp;at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)</div><div>&nbsp; &nbsp;--- End of inner exception stack trace ---</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)</div><div>&nbsp; &nbsp;at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.<SendAsync>d__5.MoveNext()</div><div>--- End of stack trace from previous location where exception was thrown ---</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)</div><div>&nbsp; &nbsp;at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.<SendAsync>d__5.MoveNext()</div><div>--- End of stack trace from previous location where exception was thrown ---</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)</div><div>&nbsp; &nbsp;at RedGate.SqlPrompt.Platform.Client.KillSwitchChecker.<GetEnabled>d__5.MoveNext()</div><div>--- End of stack trace from previous location where exception was thrown ---</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)</div><div>&nbsp; &nbsp;at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)</div><div>&nbsp; &nbsp;at RedGate.SqlPrompt.Platform.Client.KillSwitchChecker.<RunOperation>d__4.MoveNext()</div>

    A log created earlier today includes the warning shown below. Note, I've replaced the actual server name with placeholder <servername>. No changes have been made to my SQL Server database or settings aside from updating SQL Prompt.

    Also, I've been using and regularly updating SQL Prompt for several years. This is my first time encountering an issue like this. All previous upgrades continued to function as expected.

    <div>2024-04-03 08:46:23.782 -05:00 [Information] Created new ServerCandidate for server: <servername></div><div>2024-04-03 08:46:53.519 -05:00 [Warning] Failed to load server <servername></div><div>Microsoft.Data.SqlClient.SqlException (0x80131904): A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: HTTP Provider, error: 0 - )</div>

    Question, is there a way to fix the ServerCandidate connection manually? Not finding any obviously related settings in the SQL Prompt menu.
Sign In or Register to comment.