Here's a few of the new posts today on the forums. To see more, visit the forums.
|
SQL Server 2017 - Administration |
credentials running powershell monitoring scripts - I have about 5 or 6 powershell scripts I use to monitor 300 SQL Servers. I run the scripts as scheduled SQL agent jobs. I just realized I was not successfully auditing some servers because the domain account running the SQL Agent service on my "monitoring" server does NOT have access to ALL servers. What […] |
SQL Server 2017 - Development |
SQL pivot /unpivot - I have table something like below. Need the table with status1 and status2. How can i achieve that? |
How to use Tally Table to allocate quantity? - I have read many great helpful articles on Tally Tables by Jeff Moden, Lynn Pettis, and many others; however I haven't seen one on how to allocate quantities using Tally Tables. Here is how I would do it using Loop (RBAR) logic. Please give insight into how to turn it into set logic or point […] |
SQL Server 2016 - Administration |
sp_updatestats permissions issue - Hi All, while running sp_updatestats we are receiving permissions denied error. But as per below article, if we have db owner access on the database we can run this stored procedure. https://docs.microsoft.com/en-us/sql/relational-databases/system-stored-procedures/sp-updatestats-transact-sql?view=sql-server-2017 But even we have db owner privileges on user databases we are getting permissions denied error. please let me know what is […] |
Migrating Cubes from SQL 2008 to SQL 2016 issues - I have started this new Topic under SQL Analysis forum. Thought of putting the topic reference here as not many people look under Analysis forum. #3654878 Many Thanks, Vinay |
SQL Server 2016 - Development and T-SQL |
Split values after semi colon to rows - Hi, I need to split column values after ; to new rows . However receiving Create table #TestSplit ( ID INT, Stops VARCHAR(1000)) INSERT INTO #TestSplit (ID,Stops) SELECT 1,'Procure to Pay x Manage Purchase Orders' UNION ALL SELECT 1,'Procure to Pay x Manage Purchase Orders;Procure to Pay x Manage Account Payable' UNION ALL SELECT 1,'Procure […] |
Query web API and return JSON data - Hello, We use a service that provides an API for pulling our real-time data. I'm trying to retrieve that data into a table so I can build some functionality in-house consuming that data. I found a few script examples but I can't find complete documentation on the stored procedures that are referenced. The first call […] |
Administration - SQL Server 2014 |
Distribution List in SSIS - Dear All, Is it possible to send mail to a Distribution list from SSIS 'Send Mail Task'? Please advise. |
Development - SQL Server 2014 |
Optimize a stored procedure - I have a stored procedure that is called multiple times to get all the elements necessary to display the page. Sample data: CREATE TABLE #temp (plan_id INT, parentid INT, label VARCHAR(20), color VARCHAR(10), comp_id INT, start_date DATETIME) INSERT INTO #temp VALUES (607, NULL,'abc', 'CDC', 432, '2018-05-22 00:00:00'), (607,NULL,'abc', 'CDC', 432, '2018-05-22 00:00:00'), (607,NULL,'abc', 'CDC', 433, […] |
Calling same stored procedure - Hello, I have a web application which assigns a case to a user by clicking on the button "Get Case". On clicking of this button, a stored procedure is called. An existing table containing the CaseIDs is read and one ID from this table is assigned to the user who clicked on "Get Case" Now […] |
sqlcmd to export to txt file - not working - First time exporting contents of tables to a txt file. Need to keep NULLs instead of empty blanks that are generated by export wizard. So, want to use sqlcmd. Tried: sqlcmd -s servername -d dbname -E -Q "SELECT * FROM [Schema].[dbo].[Inventory]" -s "," -o "\\address.org\vdifolders$\polkadot\Documents\US570333\Inventory.txt" get error: Msg 102, Level 15, State 1, Line 1 […] |
SQL Server 2012 - T-SQL |
Determine if DB name has numerics - I am writing a script to move through specific databases in our server and if the name ends in 2 digits then I run a select statement in it. The following returns a 1 if the ISNUMERIC returns true select sd.name, ISNUMERIC(RIGHT(sd.name,2) from sys.sysdatabases sd Where sd.name not in ('master','tempdb','model','msdb') However when I run that […] |
SQL Azure - Administration |
Cluster-Aware Updating - Is it possible to use Cluster-Aware Updating in Azure? By In Azure I mean on two VMs as IaaS, with always on availability groups between the two providing HA. |
SSRS 2014 |
SSRS Report Parameters Interactive - Hi, I have a table that has a dept_id, sect_id, div_id, item_id, and description. The data will be reported on base on the users entry on dept_id, sect_id, div_id and item_id. For some reason I cannot work out the parameter entries in such a way that it is interactive depending on the user input. I […] |
SQLServerCentral.com Announcements |
Status Update 19 Jun 2019 - My apologies. I have completely slacked off here, but since the 17th of May, I've had 3 trips and 8 events to attend with prep for the site and events, including 3 weeks out of the country. I've been hoping that the site would work and someone kept an eye on things. Lots of work […] |