January 31, 2014 at 9:45 am
I have a report to run every day in SSMS. I have selected query options to send results to a file with pipe delimited results. Tomorrow, I don't want to recreated the result options. I would prefer that it be remembered - preferably as a login-specific profile setting. That way I can use that id to log in for those options and that report. No rework to do. Then, if I want to do more work in SSMS, I can log in as another id and have the normal default results-to-grid options.
My question is: Is this possible? I am not interested in SSIS package or other query-running options. I am interested in this specific question regarding the saving Results-to options from SSMS session to SSMS session.
January 31, 2014 at 9:59 am
hayden_jones (1/31/2014)
I have a report to run every day in SSMS. I have selected query options to send results to a file with pipe delimited results. Tomorrow, I don't want to recreated the result options. I would prefer that it be remembered - preferably as a login-specific profile setting. That way I can use that id to log in for those options and that report. No rework to do. Then, if I want to do more work in SSMS, I can log in as another id and have the normal default results-to-grid options.My question is: Is this possible? I am not interested in SSIS package or other query-running options. I am interested in this specific question regarding the saving Results-to options from SSMS session to SSMS session.
Those are application settings. They are not tied to a given sql login. You could probably setup a different windows user on that machine. I am not 100% certain if those settings are maintained per user. If that doesn't work I am not sure what you could do because afaik there isn't a way to script those settings.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
January 31, 2014 at 9:59 am
hayden_jones (1/31/2014)
I have a report to run every day in SSMS. I have selected query options to send results to a file with pipe delimited results. Tomorrow, I don't want to recreated the result options. I would prefer that it be remembered - preferably as a login-specific profile setting. That way I can use that id to log in for those options and that report. No rework to do. Then, if I want to do more work in SSMS, I can log in as another id and have the normal default results-to-grid options.My question is: Is this possible? I am not interested in SSIS package or other query-running options. I am interested in this specific question regarding the saving Results-to options from SSMS session to SSMS session.
for SQL2008, i beleive that setting is saved in your %appdata%\Roaming\Microsoft\Microsoft SQL Server\100\Tools\Shell\SQLStudio.bin file, which a per-windows login basis.
to have multiple settings, you'd have to set your settings, save that file separately, and swap the file in and out , say with a cmd file, when you want/don't want the saved settings you are guarding.
Lowell
January 31, 2014 at 10:12 am
As far as I can see, the results-to settings are not saved even for the same windows login.
I log in to windows as DOMAINA.userA and open SSMS using Windows Auth, set results-to options, run a query. All works fine.
I close SSMS.
I open SSMS using Windows Auth.
I run the query and get grid results.
Is there a way to get results to a file by default after logging back in?
The settings do not seem to be saved in any Windows User profile.
January 31, 2014 at 12:06 pm
hayden_jones (1/31/2014)
As far as I can see, the results-to settings are not saved even for the same windows login.I log in to windows as DOMAINA.userA and open SSMS using Windows Auth, set results-to options, run a query. All works fine.
I close SSMS.
I open SSMS using Windows Auth.
I run the query and get grid results.
Is there a way to get results to a file by default after logging back in?
The settings do not seem to be saved in any Windows User profile.
You can change the default destination for query results.
Tools -> Options -> Query Results -> Default destination for results
There is also a keyboard shortcut to change your current setting. ctrl+shift+f
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply