Viewing 15 posts - 16 through 30 (of 2,006 total)
DECLARE @DATE_VARIABLE DATETIME = GETUTCDATE();
SELECT *
FROM ( SELECT CAST(DATEADD(DAY, -[N], @DATE_VARIABLE) AS DATE)
FROM...
February 17, 2016 at 3:40 am
silverbullettruck (2/1/2016)
ChrisM/ER...Here is the full dataset i am working with and then below that is the what i need the data to look like after it is pivoted.
Sorry, I totally...
February 2, 2016 at 1:31 am
JonnoJ (2/1/2016)
1. Mainly testing database backups: restoring database backups, checking the recovered databases with checkdb and then dropping the databases. This will be production data.
Pretty sure this falls outside of...
February 1, 2016 at 8:53 am
Sorry, I totally misread the problem.
DECLARE @sql NVARCHAR(MAX);
SELECT @sql = 'SELECT RBR, '
+ STUFF((SELECT ',' + CHAR(13)...
February 1, 2016 at 8:46 am
orenk (2/1/2016)
Hey, here the second function.ItΒ΄s just for reporting, so the performance is not my top point π
Whats better then while?
Ouch π
When you can make something run better, why...
February 1, 2016 at 8:22 am
Few ways to do it, I've always preferred the cross-tabs
SELECT [pvt].[Domain],
[pvt].[CaseName],
[pvt].[Stream],
...
February 1, 2016 at 7:48 am
Also, seems you've asked this question in two forums (T-SQL and General).
I know you're probably hoping that just results in you getting an answer faster, but instead it just fragments...
January 21, 2016 at 8:34 am
Hey there,
Do you mind having a quick look at this link (http://www.sqlservercentral.com/articles/Best+Practices/61537/)[/url]? It's all about how best to post a question on these forums.
As things...
January 21, 2016 at 8:27 am
CREATE FUNCTION [dbo].[DelimitedSplit8K]
--===== Define I/O parameters
(@pString VARCHAR(8000), @pDelimiter CHAR(1))
--WARNING!!! DO NOT USE MAX DATA-TYPES HERE! IT WILL KILL...
January 21, 2016 at 6:01 am
I guess a trigger on insert that saves the data in an audit table is the temporary solution until it gets properly fixed.
January 19, 2016 at 7:48 am
Don't know what the issue is (I don't use the framework, installed it to test if I could reproduce), but if you change the sproc Private_CleanTestResult to: -
ALTER PROCEDURE [tSQLt].[Private_CleanTestResult]
AS
BEGIN
...
January 18, 2016 at 5:19 am
Sounds similar to a "catch-all" query. Have a read through this (http://sqlinthewild.co.za/index.php/2009/03/19/catch-all-queries/) blog post[/url]. There are many other posts on the topic.
September 22, 2015 at 4:04 am
Interesting. Spent an little bit of time knocking this up based on Lowell's script that was uploaded here --> http://www.sqlservercentral.com/scripts/SQL+Server+2005/67515/%5B/url%5D
SET NOCOUNT ON;
IF OBJECT_ID('tempdb..#indexes') IS NOT NULL
BEGIN
...
September 7, 2015 at 6:11 am
Edward-445599 (8/6/2015)
ServerCentral|||||forum|||||||||||||||is||||||the||best
so||||||be|||||on||||||||||||||||||||||||||||||||||||||||||||it
And i need the output in the following form:
ServerCentral=forum=is=the=best
so=be=on=it
The logic being that multiple and consecutive occurrences of...
August 6, 2015 at 2:58 am
Minnu (8/5/2015)
Below code is working.
with base as (
select
*,
rn = row_number() over (partition by user_name order by access_time desc)
from dbo.library
)
delete from base...
August 5, 2015 at 5:26 am
Viewing 15 posts - 16 through 30 (of 2,006 total)