Viewing 15 posts - 871 through 885 (of 3,480 total)
a heap is a table without an index - it's unordered. You can't reorder something that's not ordered by an index.
September 20, 2019 at 7:03 pm
Okay, sorry everybody. I found out that the question was way easier than I thought. (That's what happens when you don't get scripts to recreate the tables and data and...
September 20, 2019 at 3:44 am
I'm an Aspie too, so I can kind of see where David is coming from. talking to "paper" or typing on a computer might be easier because there's so much...
September 19, 2019 at 5:47 pm
I think I remember your article about "Find all pilots that can fly all the planes" question. (Yep, that's the one!)
Is there a way to process the "build orders" without...
September 19, 2019 at 3:00 am
Wouldn't you declare a variable to hold the filename and then use .NET functions to parse out the chunks you want that make a date? Then compare it to some...
September 17, 2019 at 11:50 pm
If you're trying to get a count of enrollments for each day, then you would need a Calendar table of some kind. Are you trying to count the number of...
September 16, 2019 at 3:59 am
Can we at least see the stored procedure code? Hard to fix something without seeing it.
September 13, 2019 at 5:30 am
Can't you just use CALCULATE() and IF/SWITCH to handle the different options? CALCULATE lets you override some or all of the current evaluation context. Wouldn't the difference between "early" and...
September 10, 2019 at 4:05 am
What's your expected result? What constitutes a "duplicate"? Two records that cancel each other out, like the last pair do?
September 6, 2019 at 9:45 pm
Oh, if you're trying to restrict groups of users from seeing rows, then use Row Level Security. \
September 6, 2019 at 5:56 pm
use data masking?
https://www.sqlshack.com/using-dynamic-data-masking-in-sql-server-2016-to-protect-sensitive-data/
September 6, 2019 at 9:30 am
Could you explain the context of what you're doing? If you have a table of days and some are marked as holidays, you don't need to store that information in...
September 6, 2019 at 4:11 am
Something like this?
use tempdb;
GO
CREATE TABLE HOLIDAY (DATEHOLIDAY DATE);
CREATE TABLE Times (DATEMONTH DATE, IS_WORK BIT);
GO
INSERT INTO HOLIDAY(DATEHOLIDAY) VALUES('2012-01-01'),('2012-02-01');
INSERT INTO Times(DATEMONTH,IS_WORK) VALUES('2012-01-01',0),('2012-01-02',0),('2012-01-03',1),
('2012-02-01',0),('2012-02-02',0),('2012-02-03',1);
Then the update is pretty simple, because the...
September 5, 2019 at 9:46 pm
If the table already exists, use INSERT INTO instead of SELECT INTO (which creates a new table)
September 5, 2019 at 7:55 pm
Can you set MAXDOP in just that misbehaving query so it runs fast while you sort out what's going on?
September 4, 2019 at 3:46 am
Viewing 15 posts - 871 through 885 (of 3,480 total)