Viewing 15 posts - 3,271 through 3,285 (of 7,609 total)
July 10, 2018 at 11:04 am
SELECT *,
CASE WHEN start_of_value = 1 THEN ''
ELSE SUBSTRING(CI_NUM, start_of_value, 5) END AS [5charsyouwant]
FROM ( VALUES('asdfasf-ABCDE-asdfasdfsfasf'),('ss-TREWQ-asdfasfsf'),
('asdfa-12-ABCDE-kindatricky'),('nothingtoseehere'),
...
July 10, 2018 at 10:49 am
So I guess it's doing a non-clustered index seek? When you go that route, you have to be careful of the "tipping point", where SQL falls back to scanning the...
July 10, 2018 at 10:44 am
100% agree with Phil. Get everything in one read and save/cache it for your app however you need to. Db read round trips (from your app to the db server...
July 10, 2018 at 8:14 am
July 9, 2018 at 3:45 pm
July 9, 2018 at 10:35 am
Btw, I'd stronbly encourage you to use:
and SQLDateTime < '2018-07-03T08:00:00 AM'
rather than:
and SQLDateTime <= '2018-07-03T07:59:00 AM'
July 9, 2018 at 10:24 am
As both of us have stated, run a CHECKDB to get an idea of the scope of the problem. One error or 100 errors?
I forgot to mention before...
July 6, 2018 at 12:38 pm
July 6, 2018 at 9:27 am
July 5, 2018 at 2:58 pm
select *
from items
where isnull(@items, '') = '' OR
exists(select 1 from DBO.Splitstrings_moden(@items, ',') where Item = item_no)
July 5, 2018 at 1:26 pm
July 5, 2018 at 9:23 am
Viewing 15 posts - 3,271 through 3,285 (of 7,609 total)