SQl Prompt Tab History Not storing new history 7.3.0.775

mike.mcguiremike.mcguire Posts: 4 New member
edited January 19, 2017 2:54PM in SQL Prompt
After upgrading to the latest sql prompt, my tab history no longer stores new history, which has been terribly frustrating. It seems to have happened after the latest upgrade but I'm not 100% positive on that. It still has old history in it, but not recent history. Please advise how to fix!

Thanks!

Comments

  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Thanks for your post and sorry to hear you're running into an issue!

    I haven't been able to reproduce this issue locally with the latest version, so it seems there is likely something machine specific that is causing this, perhaps with the SavedTabs.db file which stores the tab info.

    Can I just check--if you open or create a new query, do you see the %localappdata%Red GateSQL Prompt 7SavedTabs.db file's modify date get updated?

    If you close SSMS, rename that SavedTabs.db file, restart SSMS (which will generate a new file), and then open or create new queries, do those new tabs get stored?

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


  • I'm working on SSMS 2016 and getting the same error.
  • Thanks for your post and sorry to hear you're running into an issue!

    I haven't been able to reproduce this issue locally with the latest version, so it seems there is likely something machine specific that is causing this, perhaps with the SavedTabs.db file which stores the tab info.

    Can I just check--if you open or create a new query, do you see the %localappdata%Red GateSQL Prompt 7SavedTabs.db file's modify date get updated?

    If you close SSMS, rename that SavedTabs.db file, restart SSMS (which will generate a new file), and then open or create new queries, do those new tabs get stored?


    Hi Jessica,

    I tried this and when I create a new tab it does update the modify date on the SavedTabs.db

    As for the SavedTabs.db file when renamed and regenerated it does store the new tabs.
  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Sorry to hear you're running into this as well!

    It sounds like the SavedTabs.db files may have been corrupted then--are you alright to continue using the new file?

    I'm also curious, do you both recall which version you were using before updating? (If you happened to have had logging enabled, you can check a log file from before you updated in %localappdata%Red GateLogsSQL Prompt 7 to check the version)

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


  • I only seem to have logs back to January 5th, which shows 7.3.0.775. Was logging not enabled prior to that version, or was it in a different location? When did that level of logging start?
  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Ah okay, logging is disabled by default so you may not have logs from the previous version unless you had enabled it or chose to "Show file" at any point when it was still installed. I was just wondering if we could find out the previous version in case it's upgrading from a certain version that caused this for you both.

    Can I just check though, mike.mcguire--did renaming the SavedTabs.db file help?

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


  • Thanks for asking! It magically started working on the 16th, but that's because I rebooted. So, in the tab history, there's a jump. You see Last closed of January 5th, and then the next tab history query window that works says last closed on January 16th. Nothing got saved between the two dates. And indeed, in my logs folder, there's a log file from 1/5 that has days worth of logs in it with errors like this:

    09 Jan 2017 18:01:26,019 [1] INFO RedGate.SQLQueryKeeper.TabWatcher - Couldn't mark document as closed
    System.ArgumentException: The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
    at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
    at Microsoft.VisualStudio.Platform.WindowManagement.Rdt.FindAndLockDocument(RdtFlags flags, String moniker)
    at Microsoft.VisualStudio.Platform.WindowManagement.DTE.DocumentWindows.Impl..ctor(Document document)
    at Microsoft.VisualStudio.Platform.WindowManagement.WindowManagerService.get_DocumentWindows(Document document, Windows& windows)
    at EnvDTE.Document.get_Windows()
    at RedGate.SQLQueryKeeper.TabWatcher.<WindowClosing>b__44_0()

    And there's another log file from the 16th and no errors in it. Clearly I should have just restarted. I'm sorry for the noise, but I hope this helps you in that there's some kind of issue on the upgrade that required some kind of reboot to fix.
Sign In or Register to comment.