Viewing 15 posts - 571 through 585 (of 7,191 total)
Sam
Looks like you need to do a bit of normalising first - you shouldn't have ProductID and productname in a table of sales. Assuming changing that isn't an option,...
November 29, 2018 at 7:16 am
I would guess that Profit_Percent and Commission_Percent have character data types, and there's values in one or both of them that can't be converted to decimal(10,2).
John
November 28, 2018 at 8:24 am
Thanks again.
I've been trying to find a better way to look at the FROM statement. I've always...
November 27, 2018 at 1:48 am
Might be worth trying querying the plan cache. Have a look at the query on this page, and put total_logical_writes in the query. Then, in the result set, look for...
November 26, 2018 at 9:14 am
It was that long list of table joins without a line break that spooked me!
Here are the changes I made:
(1) COALESCE instead of CASE makes the code...
November 26, 2018 at 9:02 am
Please post your code your code (and for the sake of your colleagues and future self, lay it out) in a format that's easy to read. It's difficult for others...
November 26, 2018 at 7:42 am
My suggestion is not to call jobs from triggers. What happens if a job is already running when the trigger that calls it fires? What if SQL Server Agent is...
November 22, 2018 at 4:45 am
You've posted in the SQL Server 2008 forum. Is that the actual version you're using? If so, I don't think there's anything you can do, short of capturing all plans...
November 19, 2018 at 9:45 am
The creation_time column - is that what you're looking for?
John
November 19, 2018 at 9:30 am
You've posted in the SQL Server 2008 forum - is that the actual version you're using? If you're on SQL Server 2012 or above, you can use TRY_CONVERT. If you...
November 19, 2018 at 4:37 am
November 19, 2018 at 2:38 am
Understood, but if it were me I'd rather prevent any anomalies than try to capture and correct them after the fact. In the worst case, there could be hundreds or...
November 16, 2018 at 5:40 am
If you're deleting 20 million rows one at a time, of course it's going to be slow. Do it in one go - that's what RDMSs are designed for. If...
November 16, 2018 at 4:41 am
Your programmers ought to be in the habit of adding comments to an object definition every time they create or alter it. You can quality check this yourself, since you...
November 14, 2018 at 9:51 am
Save it as a .sqlplan file and attach it to your post.
John
November 14, 2018 at 7:15 am
Viewing 15 posts - 571 through 585 (of 7,191 total)