Here's a few of the new posts today on the forums. To see more, visit the forums.
|
SQL Server 2017 - Administration |
Auditing selective users - Hi, I am putting together sql server auditing for a certain project. I create a sql server audit object (which writes audits to file). Then I create a database audit specification. First I used public as principal CREATE DATABASE AUDIT specification [DBAuditSpec] FOR SERVER AUDIT [DBAudit] ADD (SELECT, INSERT, UPDATE, DELETE, EXECUTE, RECEIVE, REFERENCES ON […] |
Create index ... online=ON - Why is this INDEX setting not persistent ? I'm testing this on SQL2019, but I've seen the same thing on SQL2016. I run this CREATE NONCLUSTERED INDEX [ImageActID] ON [dbo].[Image]( [ImgID] ASC )WITH (SORT_IN_TEMPDB=OFF, DROP_EXISTING=ON, ONLINE=ON, ALLOW_ROW_LOCKS=ON, ALLOW_PAGE_LOCKS=ON) ON [PRIMARY] GO Then I refresh and right click on the index and select "Script index as […] |
SQL Server 2017 - Development |
simple insert statement issues - Hello, create table #temp2(datename datetime, lastprocessed datetime DEFAULT'getdate()' NULL) insert into #temp2(datename) select distinct convert(date, c.ActualDate, 101) AS [DateName] from dim.calendar c select * from #temp2 I get below error when I run above Msg 241, Level 16, State 1, Line 20 Conversion failed when converting date and/or time from character string. |
ssas tabular model view - Hello, I have a SQL DB where we have created some views based on dim and fact tables. I need to build SSAS tabular model based on my tables and views. But one of the view runs for 1.5 hour inside SQL query (SSMS). Now I need to use this same view to build my […] |
SQL Server 2016 - Administration |
Adding 3 rd node in Alwayson - Hi, We have 2 node Alwayson setup. Planning to add 3rd node. To add 3rd node, do we need to remove databases from AG and re-configure them from scratch after adding 3rd node? |
SQL Server 2016 - Development and T-SQL |
Deduplicating records from monthly table backups? - I have a database that has monthly backups of a table for the past five years... i.e., they copied the table at the end of the month to a table called theHugeTable_mm_yyyy. Now as you can imagine, tables are huge... and the majority of the table data didn't change from one month to the […] |
@@TRANCOUNT - The question is: What is @@trancount after this SP is executed? I don't understand why the answer is 1. My understanding is for every BEGIN TRAN, @@TRANCOUNT is incremented by 1 and for every COMMIT, @@TRANCOUNT is decremented by 1, so why is the answer not 0? I know it has to do with the […] |
Help on excluding dates - I have a simple table where I need to exclude any dates that weren't within 3 days of the max date. I can't use aggregates in WHERE or HAVING clauses, so looking for an easy to way to exclude a date when it's more than 3 days diff from max date. Here's some sample data: […] |
Administration - SQL Server 2014 |
Upgrading from SQL 2008R2 SP1 to SQL 2014. - Hi guys, I'm planning to perform an upgrade on my current SQL server 2008R2 SP 1 to SQL Server 2014. Based on my current license limitation 2014 is the max I can go. I read KB by Microsoft, I need to be on at least SP2 for the upgrade to be successful (https://docs.microsoft.com/en-au/sql/database-engine/install-windows/supported-version-and-edition-upgrades?view=sql-server-2014) if this […] |
Development - SQL Server 2014 |
Guaranteed Varchar to Date conversion - I regularly load in multiple files using SSIS into a staging table and then onto another table (I call them trans as they are never fixed). The data goes into stage as it comes out of the file or other source. This way I can always prove I took in what I was supplied. Stage_policy […] |
SQL Server Newbies |
* to 1 - Can I replace the * with 1 here in the below code. Will it impact the result. IF EXISTS (SELECT * FROM dbo.tbTest where Test_ID = @Test_ID) -- Like change to SELECT 1 |
Azure Machine Learning |
Why no posts? - I've heard Microsoft promote their concept of the "modern data warehouse" and their tools to support machine learning. In my mind, there are at least 2 big components embedded in what they say: marketing to promote adoption of their cloud services and genuine opportunities to add value to the community. When I hear the word […] |
Integration Services |
Automate the SSIS package to take Start and enddate - I have a master/parent package, that calls the child packages in SSIS. The Master package takes the startdate and enddate and get all the dates from the given Startdate and enddate and run the child packages in loop. Example: Startdate = 1/1/2019' and Enddate ='1/10/2019'. SO the Master loops through 9 times meaning 1-9th january […] |
PowerPivot |
Power BI Data Gateway - Azure VM v On-Premises - When you have a SQL Server instance running in an Azure VM and you want to connect Power Bi Data Gateway to it, do you install the Data Gateway or is there another way for Power BI to get the data, considering it isn't technically "On Premises"? |
Suggestions |
APP - Hi, Just a thought and sharing. Forum is great and it helps. However how about an app like an Iphone or Android app... which lets you post quick questions? I am not sure if there is already one. It will let the user post questions when there is no access to a laptop or on the […] |