Using WHERE Not Exists for a Fact Table Load
I have a stored procedure in that attempts to perform a WHERE NOT EXISTS check to insert new records. If the table is empty, the procedure will load the table. However, an insert does not occur when a...
View ArticleSplit out a field of comma separated values based on a unique code in the...
HiI have a comma separated field containing numerous 2 digit numbers that I would like splitting out by a corresponding unique code held in another field on the same row.E.gUnique Code Comma Separated...
View ArticleWhen to use IDs
Hello,For many years I have always used id's (auto increment integers) for everything rather than storing data on the table.Let me explain by a very simple example, lets say I have a Customer table,...
View ArticleMasking (Deidentification)
Hi,I have a table. I have some sensitive data that I don't want to display that sensitive data. The columns I want to abstract areFirstname varchar(50) not nullLatname varchar(50) not nulldob datetime...
View ArticleNew cardinality estimator (SQL Server 2014) is way off
I have a data warehouse database and I'm facing problems with the new cardinality estimator of SQL Server 2014.After upgrading the database server to SQL Server 2014 I have observed a big difference in...
View ArticleAutomated deployments, Team City, Octopus Deploy
Hello everyone,I am currently managing a development teams automated deployment of a .net web application with a sql server backend.We are SVN as our source controlWe currently have fully automated for...
View ArticleAnyone want to go to the PASS Summit in Seattle?
A last minute issue has prevented me from going. Selling the registration on e-bay to try and recoup some...
View ArticleMerge Replication synchronization in Stored procedure
I'm updating some tables in a subscriber database with a stored procedure. After the tables get updated I'd like to sync them with the other subscriber dbs and the publisher db in that same stored...
View ArticleEasy question, is the Projects folder and the Code Snippets folder
Very, very simple question here. I'm using SQL Server 2014 Developer Edition, to improve on my SQL skills. I'm using to saving my SQL code in a folder under [b]Documents\SQL Server Management...
View ArticleSQL Query - Should be easy fix???
Hi,Sorry I know this is going to be an easy fix but I'm just starting out with SQL scripting.I have the following query which has inner joins and is fine on the first join however when I enter the...
View ArticleSQL CLR Function and .NET Framework return different results
Hello, everyone.I have rather simple CLR function:[code="vb"][SqlFunction(IsDeterministic = true, DataAccess = DataAccessKind.None)]public static SqlString GetUserName(){ return...
View ArticleDo we require to install SSMS to run SQL Script in command Prompt.
I tried to install SQL Server 2008 Native Client and I am not able to run the SQL script using command Line. I am getting an error "SQL type is not recognized..." So My questions is here.. is there any...
View ArticleSemantic Search not finding keywords identified by Full-Text Search
I have a scenario of where the standard Full-Text search identifies keywords but Semantic Search does not recognize them as keywords. I'm hoping to understand why Semantic Search might not recognize...
View ArticlePublic Function Custom Code SSRS 2014
I'm trying to convert a 2005 .rdlc to a 2014 .rdl. There is custom code that no longer works after the conversion. One field would have code snippets for it like this in the code: <Textbox...
View ArticleStored Procedure with override?
I received a request to create a stored proc with following:I have a view with the following columns(table1 - AppCode, AgencyID, CompnyID, CustCode, CustVal)I have a proc that will take the following...
View ArticleDoubt in memory OLTP table
Hi Experts,Wondering to know how to handle this situation.I would like to address performance issues in production so I would want to make some table(s) as in memory residing table(s). So that entire...
View ArticleSQL 2014 Developer Edition
Hi, I've read a few posts around the internet about this, but they all point to the Microsoft site for information and I can't find the answer to my question on there.I have SQL server 2005 and 2008 R2...
View ArticleSQL User without Login
I know this question miught be pretty easy. But I am new to SQL security. I created SQL User without Login so that my application can always write to the database even if the user's don't have such...
View Article