What are the challenges you face when working across database platforms? Take the survey

Mouseover hints very inconsistent in existing queries

RichBev61RichBev61 Posts: 6
edited January 29, 2009 11:23AM in SQL Prompt Previous Versions
If I open an existing stored proc for editing in SSMS, some objects will show proper hints on mouseover, but others will not. Some observations:

* UDFs and builtin functions and stored procs will show hints on some lines of the query while the same objects will NOT show mouseover hints on other lines.

* Still, other times the same lines that did show hints, will not show hints on subsequent mouseovers if something changed like window scrolled.

* Sometimes, copying objects that do not trigger hints and pasting to another line will trigger hints on the new line.

* In all cases the code is from existing Procs or UDFs and the code is in production and working just fine, so there's not a syntax issue, etc.

* SSMS (not express, client tools installed only) v9.0 (2005)
* installed and running from a beefy desktop machine
* connected db on virtual server hosted on local domain on gigabit network connection
* SQL prompt v3.9.0.43
* Entire SQL Prompt Bundle installed on desktop

Any ideas?


  • Options
    I've now had the opportunity to check out more existing code (my product has over 500 procs) and I'm finding more procedures and functions that seem to have no problems displaying proper hints. Although the behavior doesn't seem to have any obvious reasons for existing. A table that fails to trigger a hint in one procedure triggers just fine on another.
  • Options
    EdCardenEdCarden Posts: 137 Silver 2

    This may or may not be of help. I too have found my SSMS does the same thing and from what I can tell it is more often then not caused by what I just typed or what preceeeds the typing of the function. For example if I jump my cursor back to some point in the SELECT clause and type a function name the Mouse Over Hint does not appear. If however I then back space to the preceeding comma that seperates the fields in my SELECT clause and then re-type the comma and tehn retype the function the mouse over will then work.

    My guess is that SQLPrompt needs some preceeeding info to properly determine what you are tyoping next, in turn to understand that you are typing the name of a function that it need to provide mouseover info on.

    In other words I don't think SQLPrompts mouseover hints will work anywhere you have the name of a function. If you type the name of a function in a comments section for example I don't think SQLPrompts mouseover will show info on the function when you hover over it.

    Make sense?
  • Options
    My reasoning behind similar behaviour is that if the script i have doesnt parse then the hints seem not to function.

    When you get the problem next time try hitting Ctrl+K, Ctrl+Y to see if the layout feature works. My experience shows that this fails with a SQL parse error. Also try the 'Parse' tick button next to execute in the defaul SSMS toolbar.

    Fix the script 'error' and see what effect this has on the hints feature ...

    [I put error in inverted commas there as sometimes is not an error as in a mistake but an error as in an incomplete section of code.]


    Senior DBA
    Careers South West Ltd
  • Options
    Ed, Jack... thanks for the replies.
    Unfortunately, I've been pulled to other non-db related tasks lately and haven't had time to explore more, but here are some facts/observations based on your replies:
      * These anomalies seem to occur mainly in a few existing functions and procedures not when actively typing.
      * the existing code is in production with no syntax or other uncompilable errors.
      * I too, noticed that if I retyped or even copy-n-pasted the line that fails to trigger hints to the line above or below, it will then trigger the hints.
      * I thought that maybe some unprintable ascii characters existing in the old code might be the culprit, but after copy-n-pasting into notepad ++ and showing all characters, nothing seemed abnormal.
      * Finally, I tried re-formatting with SQLpromt's layout feature, as suggested and oddly enough, many of the objects that failed to trigger or triggered inconsistantly, now trigger consistantly. BUT... a few items in the same proc still fail to trigger hints.

    Wierd... but not a deal breaker... I still LOVE using the tools. Makes SQL less of a chore to work with.
Sign In or Register to comment.