Viewing 15 posts - 136 through 150 (of 424 total)
I had trouble following along and ended up using tutorials from the internet. I'm using Excel 2016. Type "Power view" into help, to get a long list of...
May 4, 2016 at 1:18 pm
The "date" datatype does not contain time.
I think you want something like this:
DECLARE @h TABLE (Hr int not null);
INSERT into @h values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11),(12),(13),(14),(15),(16),(17),(18),(19),(20),(21),(22),(23);
SELECT * FROM @h;
DECLARE @t TABLE (dt_arrival datetime...
April 28, 2016 at 2:36 pm
Run these to see what your server settings are. The last column is the value I would expect.
select 'ServerSetting', 'DefaultLangID', @@DEFAULT_LANGID, '0'
UNION all
select 'ServerSetting', 'DefSortOrderID', @@DEF_SORTORDER_ID, '52'
UNION...
April 27, 2016 at 3:04 pm
I run this on customer sites to make sure SSMS text won't get chopped.
-- First run this test
-- is ssms configured for 8192 char output in text mode?
SET NOCOUNT ON;
DECLARE...
April 27, 2016 at 2:39 pm
Have you checked your SSMS tools-options text and grid output truncate length settings?
Maybe characterset settings are affecting things.
Are you concatenating a zero byte in the middle? A zero byte...
April 27, 2016 at 2:03 pm
I suspect a trigger might be converting it to nvarchar and back.
There may be implicit conversions to nvarchar and back if you use some built-in functions.
I suspect SSMS query environment...
April 27, 2016 at 1:46 pm
Sql Server 2008 r2 can't handle the IIF functions. So I reformatted your code and got it working.
/* ** Agent Job List ******************************************************** **
** Description: Create a list of agent...
April 22, 2016 at 12:39 pm
Well, I started on Sql Server 4.21 back when there was no DRI (declarative referential integrity) nor table checks so triggers were the only way to go as a single...
April 20, 2016 at 12:19 pm
So you want to compare the tree structure and not the values, correct?
I've used this dbo.XmlTable function to do it. Get the function from here:
http://beyondrelational.com/modules/2/blogs/28/posts/10495/xquery-lab-58-select-from-xml.aspx
And here is some simple...
April 19, 2016 at 9:04 am
The "Joel Test" in Steve's link is right on target for the Project Leader. I work at a software development company and we always succeed in our projects, on...
April 14, 2016 at 2:01 pm
Here is something that is not a joke: Microsoft is working on getting sql server running on Linux by next year.
April 1, 2016 at 7:06 am
A login is for Authentication.
A User is for Authorization.
March 17, 2016 at 7:21 am
Here is another possible way to delete a duplicate row:
-- delete all duplicates but first in each set
WITH cte AS
(
SELECT a.*,
ROW_NUMBER() OVER(PARTITION BY col1, col2 ORDER BY col1,...
March 9, 2016 at 12:01 pm
The cartoon chart is irrelevant in cases where I want to be prepared to solve crises in seconds; it may take me hours or days to create scripts, say, to...
March 7, 2016 at 11:12 am
Viewing 15 posts - 136 through 150 (of 424 total)