Viewing 15 posts - 631 through 645 (of 2,452 total)
I am a little confused on your post(s)...but that maybe a language issue.
you speak about a "resultant" table...can you clarify is this the actual db table you require to be...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 4, 2016 at 12:22 pm
Wayne West (6/3/2016)
Among many places, you can find it here.
many thanks
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 3, 2016 at 3:26 pm
Ed Klein-385786 (6/3/2016)
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 3, 2016 at 2:50 pm
have you considered using "CASE WHEN...THEN...ELSE...END"
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 2:59 pm
yb751 (6/1/2016)
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 12:27 pm
desired results for you
+-----------------------------------------------------------------------------------------------------------------------+
¦ DESIRED QUERY RESULTS ...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 10:42 am
yb751 (6/1/2016)
hmmm...yeah that throws a wrench in things. I just wished we knew more.
hehe....pity the OP didnt post an update when (s)he peeked out from behind the sofa, half...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 9:18 am
some more testdata to play with
CREATE TABLE #yourtable(
id INTEGER NOT NULL
,alert_code ...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 9:09 am
as an example of how to present some sample data see below and here https://spaghettidba.com/2015/04/24/how-to-post-a-t-sql-question-on-a-public-forum/
CREATE TABLE #yourtable(
id ...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 8:10 am
mikes84 (6/1/2016)
.....using a method that does not require a Tally table, CLR, or any functions.
any reason why no Tally or functions?
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 6:56 am
should the code have been
CREATE TABLE Mytest (id XML, x XML)
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
June 1, 2016 at 3:00 am
shagil.a.gopinath (5/31/2016)
Still its not meet my requirement, i need only the total hours as result. In the below query i get the total hours but i am not able...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
May 31, 2016 at 8:19 am
I gave response on your other thread.....please dont double post
http://www.sqlservercentral.com/Forums/FindPost1790784.aspx
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
May 31, 2016 at 8:08 am
I trust you understand that DATEDIFF returns the count of the specified datepart boundaries crossed between the specified startdate and enddate.
eg...even though the start and end times below are only...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
May 31, 2016 at 4:37 am
Onthe assumption (dangerous I know!) that the inactive records always appear as two consecutive rows when ordered by site/datetime then the following mayhelp
CREATE TABLE [dbo].[Temp2](
[SiteCode] [int] NULL,
[StatusTime] [datetime] NULL,
[Status] [char](2)...
________________________________________________________________
you can lead a user to data....but you cannot make them think
and remember....every day is a school day
May 31, 2016 at 4:16 am
Viewing 15 posts - 631 through 645 (of 2,452 total)