Viewing 15 posts - 121 through 135 (of 4,080 total)
Just thought I'd mention that I tried both cte tally schemes and they produce a different number of rows. Jacob, yours seems to produce a doubled result set.
March 27, 2018 at 11:14 am
I agree that getting some timings across steps would help you isolate the problem.
IMO, you do NOT want to try to join to a view on a linked...
March 27, 2018 at 11:01 am
Good luck with that. Be advised that our company has quit using linked servers because of security issues.
Also, using SSIS or multiple "pulls" of data are permitted...
March 27, 2018 at 10:50 am
If you are trying to update data on Server B with a procedures or script running on Server A, then you are attempting what is called a "distributed transaction". Requirements for distributed...
March 23, 2018 at 4:21 pm
SQL Server Integration Services (SSIS) is another option.
March 23, 2018 at 3:37 pm
Agreed. If instead of updating, you want to delete all rows then re-insert them, you can't make MERGE do it. You have to code a DELETE statement followed by an INSERT...
March 23, 2018 at 3:31 pm
I know that this topic has been over for a while but....
Be aware that at distances of 100 feet (or even 20 miles) there is little need to...
January 20, 2018 at 8:55 pm
Can you try IN, instead of OR... that can sometimes produce two index seeks against one table instead of a scan.
January 20, 2018 at 5:49 pm
@Patrick123 (11/8/2016)
without Cte i want to delete
Why? It does the job well.
Try this.
delete a
from #temp a
inner join employee e on a.id = e.id
-- Put the selection criteria...
November 8, 2016 at 4:48 pm
My error. I usually put the WHEN MATCHED logic first. Thanks, Drew. 🙂
November 2, 2016 at 1:00 pm
I would never have forgiven myself if I missed this one.
I'm just glad the date wasn't Thanksgiving.
November 1, 2016 at 3:29 pm
if ID 001 gets another record with sequence 3 , then this record should go as an insert in target.
So far you've only coded for an UPDATE on a match....
November 1, 2016 at 3:11 pm
There are a lot of users (and developers) who, while competent in their own fields, are going through a learning curve for SQL. There is no...
October 21, 2016 at 11:00 am
If I may step for a moment, I would like to reiterate that the point of the calendar table is to simplify queries for all users, not just...
October 21, 2016 at 9:33 am
Hey Jeff, could you send me private message with your email? Your box is always overflowing.
Also, I need to know where to send...
October 13, 2016 at 3:52 pm
Viewing 15 posts - 121 through 135 (of 4,080 total)