Viewing 15 posts - 4,366 through 4,380 (of 26,490 total)
Jeff Moden (10/20/2015)
Lynn Pettis (10/20/2015)
Alvin Ramard (10/20/2015)
Or:
d eclare @testTime char(5);
set @testTime = '23:45';
SELECT @testTime = cast(dateadd(minute, 15, cast(@testTime as time) ) as char(5));
SELECT @testTime;
But with the above, the following...
October 20, 2015 at 12:09 pm
Alvin Ramard (10/20/2015)
Or:
d eclare @testTime char(5);
set @testTime = '23:45';
SELECT @testTime = cast(dateadd(minute, 15, cast(@testTime as time) ) as char(5));
SELECT @testTime;
But with the above, the following will also work.
select @testTime...
October 20, 2015 at 12:03 pm
Alvin Ramard (10/20/2015)
Or:
set @testTime = '23:45';
SELECT @testTime = cast(dateadd(minute, 15, cast(@testTime as time) ) as char(5));
SELECT @testTime;
Remember, the OP is working with SQL Server 2005 so no time data...
October 20, 2015 at 11:57 am
ITU_dk2012 (10/20/2015)
I will try to post more data and expected results in my next post.Thank you all for your great help.
What ever you post needs to be as close to...
October 20, 2015 at 11:42 am
Jack Corbett (10/20/2015)
Lynn Pettis (10/20/2015)
Jack Corbett (10/20/2015)
October 20, 2015 at 11:39 am
Use them a lot. Easy question, didn't even need to run to verify.
October 20, 2015 at 11:34 am
Try this:
set @testTime = '23:45';
select @testTime;
select @testTime = convert(varchar(5),dateadd(minute,(cast(left(@testTime,2) as int) * 60) + cast(right(@testTime,2) as int) + 15,cast('1900-01-01' as datetime)),108);
select @testTime
go
October 20, 2015 at 11:25 am
ChrisM@Work (10/20/2015)
Ed Wagner (10/20/2015)
Luis Cazares (10/20/2015)
Brandie Tarvin (10/20/2015)
Ed Wagner (10/20/2015)
Alvin Ramard (10/19/2015)
ITU_dk2012 (10/19/2015)
October 20, 2015 at 11:12 am
Jack Corbett (10/20/2015)
October 20, 2015 at 11:10 am
Kristen-173977 (10/20/2015)
Lynn Pettis (10/19/2015)
October 20, 2015 at 10:31 am
david 70530 (10/19/2015)
Thanks
date_time_txttestConvert
NULLNULL
NULLNULL
2015-08-01...
October 19, 2015 at 7:53 pm
m.rajesh.uk (10/19/2015)
Need query to make 'is_cleanly_shutdown' to 0 in sys.databases
My guess is that if this value isn't zero, you may have a problem and should look at running DBCC CHECKDB....
October 19, 2015 at 6:19 pm
Would something like this work?
declare @InputValue as varchar(50)='ttttest',
@Word varchar(50);
with e1(n) as (select 1 from (values (1),(1),(1),(1),(1),(1),(1),(1),(1),(1))dt(n)),
eTally(n) as...
October 19, 2015 at 4:57 pm
latingntlman (10/19/2015)
It turned out to be an access violation issue inside the batch file: The login user's password had expired. Problem fixed.
Glad you found it.
October 19, 2015 at 4:16 pm
ITU_dk2012 (10/19/2015)
Ok got it. I hope I get some help over here then. I have already posted the sample data.Thanks.
Yes, yes you did. But you didn't post your expected...
October 19, 2015 at 4:14 pm
Viewing 15 posts - 4,366 through 4,380 (of 26,490 total)