Viewing 15 posts - 391 through 405 (of 444 total)
...within 30 days from what ?
Pls try restate the problem it terms like "To incude this row in a result set there must [not] exsist rows such that..."
Particulary, what...
October 3, 2014 at 6:15 am
OK.
But when file is converted to NVARCHAR, you may live with CHAR(160) as well.
select col.value('myData[1]/@myAttr', 'nvarchar(50)')
from
(select CAST(N'<myData myAttr="12'+char(160)+ N'34" />' as XML)) as...
October 3, 2014 at 2:47 am
Which way have you figured out the symbol in error? Note in the message type of
XML parsing: line 1, character 77, illegal xml character
reported position is the position in the...
October 3, 2014 at 1:27 am
Note today is 1st of October.
If you need data as it's still September, set @now as needed.
October 1, 2014 at 8:05 am
More Integer Math less RIGHT 🙂
PRINT '========== Integer Math RIGHT(RIGHT) Method =========='
SET STATISTICS TIME ON;
SELECT @Bitbucket = RIGHT('000000000'+RIGHT(C1*1000+C2,9),9)
FROM #TestTable;
SET STATISTICS TIME OFF;
...
October 1, 2014 at 3:00 am
Then just reverse join order. You may also need to ajust BETWEEN to exact month's first / last days as you do it in your original query. See below
SELECT
...
October 1, 2014 at 2:35 am
happycat59 (9/29/2014)
With the SELECT statement as it stands, you get a different result depending on, for instance, which database you run it in.
+1
September 30, 2014 at 12:19 am
Plain CASE will help
create table #StuDetails(City varchar(25),StuStatus varchar(25), currentValue int,Week1 int,week2 int,week3 int,week4 int)
insert into #StuDetails values('A','new',13,10,0,0,12)
insert into #StuDetails values('B','Old',10,10,41,0,12)
insert into #StuDetails values('C','Fail',10,9,0,0,5)
SELECT City, StuStatus, currentValue
,Week1 = CASE week1...
September 29, 2014 at 7:28 am
Gagandeep Singh (9/27/2014)
2Change11/10/2014 1:012/3/2013 2:04
Really Start > End is OK? Explain please.
Try this quey to enumerate all intervals, including open ones. Restriction: no 'On's after 'On' or 'Off's...
September 29, 2014 at 2:30 am
Is'n it the expressions you need?
select
timeStart = dateadd(hh, datediff(hh, 0, getdate()) , 0)
,timeEnd = dateadd(hh, datediff(hh, 0, getdate()) + 1, 0)
September 24, 2014 at 4:31 am
If rounded interval is needed
SELECT
timeStart =
DATEADD(MINUTE
,-DATEPART(MINUTE,getdate())
,DATEADD(SECOND
,-DATEPART(SECOND,getdate())
, DATEADD(MS,
-DATEPART(ms,getdate())
,getdate())))
,timeEnd =
DATEADD(MINUTE
,-DATEPART(MINUTE,getdate()) + 60
,DATEADD(SECOND
,-DATEPART(SECOND,getdate())
, DATEADD(MS,
-DATEPART(ms,getdate()) - 1
,getdate())));...
September 23, 2014 at 2:46 am
The split function you cited returns table of VARCHAR(8000) because this is what Item = SUBSTRING(@pString, l.N1, l.L1)
returns due to it's first argument type. Provided Call_Detail_Report_Repository.NodeTraversed is...
September 23, 2014 at 1:02 am
For example, above DVM will count rows inserted by uncommited transactions. SQL Server 2008.
Open two queries in Managment Studio. In first query run
CREATE TABLE [testDVM](
[a] [int] NULL
) ON [PRIMARY]
GO
BEGIN TRAN;
INSERT...
September 23, 2014 at 12:32 am
Note DM view do not take care of transactions. SELECT COUNT(*) and DM may return different number of rows.
September 22, 2014 at 8:16 am
Eirikur Eiriksson (9/22/2014)
When using an identity property to maintain the sequence, re-inserting would simply imply an identity insert. On the other hand, temporal sequence would be both more robust and...
September 22, 2014 at 2:51 am
Viewing 15 posts - 391 through 405 (of 444 total)