Viewing 15 posts - 406 through 420 (of 1,229 total)
ShinyK (11/10/2016)
November 10, 2016 at 11:52 am
...CounterpartyAccountKey and GenevaAccountKey ..
If these do represent the source, think of the maintenance nightmare when the source changes, or another is added. This is not the way to design IMHO....
November 10, 2016 at 10:39 am
What is the rule if you have three people named Bo Derek, or four people named Joe Smith? In the prior code run I see that the last one...
November 9, 2016 at 11:59 am
komal145 (11/8/2016)
Thank you. Merge join worked .
Just a note, make sure the input streams are sorted in the same manner. I have seen where they were not and the data...
November 9, 2016 at 11:37 am
Assuming it is the 'Sick' hours that you are mainly focusing on , the following is as simple as I can code it:
selectcid,
sum(case when hr_type = 'sick' then 0...
November 9, 2016 at 11:09 am
Are you querying everything from one table or doing some type of join(s)?
November 9, 2016 at 10:56 am
Thanks Steve. Good straightforward question. I take it the capital Q means Quit (I'm not a sqlCmd user).
November 9, 2016 at 10:46 am
Koen Verbeeck (11/8/2016)
Somehow completely missed that the data type was bit.Moar caffeine needed!
Ok maybe the defaulting of the bit field to 'false' is a little "bit" tricky. Part of the...
November 8, 2016 at 11:25 am
Ditto,
First name can be 'John' OR 'Linda' but cannot be both at the same time (which is what a AND condition is implying).
November 7, 2016 at 10:58 am
I figured B, though I was struggling with D and was glad that the options were this or not this rather than figuring out the math on D 🙂
November 4, 2016 at 6:13 pm
This may not sound elegant, but a two step approach is to query out the entire xml string with the Results To File setting selected. Save the results to a...
November 3, 2016 at 11:49 am
Tommy 70494 (11/2/2016)
Thank you!it works, right out of the box.
I don't know why I didn't think of this.
I guess I got caught up in the fact that it was XML.
The...
November 2, 2016 at 11:58 am
Briceston (11/1/2016)
November 2, 2016 at 11:26 am
Does this help ?
DECLARE @tbl TABLE
(
id INT,
col XML
)
INSERT INTO @tbl
VALUES
(1,'<name><name1>aht</name1></name>'),(2,'<name>6</name>')
select *
from @tbl
where col.value('(/name)[1]','varchar(10)')='aht'
November 1, 2016 at 7:07 pm
Ed Wagner (11/1/2016)
I had to read it twice because I was looking for the trick. Nice, straightforward question. Thanks.
Thanks Ed. No tricks, though it is the day after...
November 1, 2016 at 12:30 pm
Viewing 15 posts - 406 through 420 (of 1,229 total)