Viewing 15 posts - 1,756 through 1,770 (of 3,507 total)
Luis' answer is super cool...
The Calendar table has some advantages... you can filter out any pattern you want (certain days of the week, days of year, etc) and its super...
October 24, 2016 at 5:08 pm
So it's simple.
do an outer join to get the non-matching records, then wrap that in an insert statement.
INSERT INTO DestinationTable(col1, col2, col3)
SELECT colA, colB, colC
FROM SourceTableA a
LEFT JOIN SourceTableB b
ON...
October 24, 2016 at 3:13 pm
If you want to add the non-matching records and update the existing ones, read this thread... Paul White knows his stuff.
October 24, 2016 at 2:25 pm
You would need another table containing all the names, and then outer join it.
SELECT n.FirstName
, tS.CaseID
,...
October 24, 2016 at 1:34 pm
You could start with a standard Calendar/Date table and then add the Fiscal Month, Quarter, Year etc.
Here's [/url]a basic Calendar table
This one[/url] might be good for a Calendar dimension...
but...
October 24, 2016 at 11:45 am
There are Calendar table examples here...
Here's [/url]a really good intro
and then Marie Bayer wrote a bunch of scripts for creating them... here
October 24, 2016 at 10:18 am
You need a calendar table, though, so you can force the existence of days where there are no bookings. You do that like this:
SELECT ...
FROM Calendar c LEFT JOIN Booking...
October 24, 2016 at 10:13 am
If you're counting values per day, you're missing the Calendar table. If you left join the Calendar table to the table of scheduled events, then it's stupid easy. You need...
October 24, 2016 at 9:53 am
Something like this:
SELECT *
FROM
(SELECT 1 as PersonID, '2016-10-21 11:00' as evntTime, 'CLOCK_IN' as evntType
UNION ALL
SELECT 1, '2016-10-21 20:45', 'CLOCK_OUT'
UNION ALL
SELECT 1, '2016-10-22 3:45', 'CLOCK_IN'
UNION ALL
SELECT 1,...
October 23, 2016 at 10:31 am
Power BI is, to some degree, like Microsoft took all the PowerPivot/tabular tools out of Excel and put them in a standalone application. You can use it for data modeling,...
October 21, 2016 at 3:56 pm
Wendy,
You could do create a job to run a stored procedure on a schedule to do this.
If you wanted to just send messages, you could do something like:
1. open...
October 20, 2016 at 12:13 pm
Use DelimitedSplit8K or something like it and then use LIKE in the join?
October 20, 2016 at 11:39 am
Something like this maybe?
DECLARE @NameTest varchar(20)
DECLARE @id INT = 1
SELECT *
FROM NameList WHERE FirstName = COALESCE(@NameTest,FirstName)
AND ID = @id;
October 19, 2016 at 7:05 pm
I was using 2003, so things may have changed. I thought MS gutted security in Access... maybe I'm wrong.
October 13, 2016 at 5:50 pm
One way is to create a place holder and use FIRST to get only one record (otherwise your report will error out when rendering).
Something like this:
=First(Fields!OpenToEnrollDate.Value, "Enrollment")
where you specify the...
October 13, 2016 at 3:03 pm
Viewing 15 posts - 1,756 through 1,770 (of 3,507 total)