Viewing 15 posts - 106 through 120 (of 134 total)
It seems from the wording of your original post that you may want this to be a computed column in a permanent table. Unfortunately, window functions cannot be part of...
April 29, 2013 at 12:08 pm
I believe this is not so much a question of grouping data as it is in presenting it. It would appear you want the left two columns sorted by GroupID...
April 29, 2013 at 11:51 am
I did some checking on a small sample of data (included with a solution below), and I discovered that the OBSValue works just fine as a datetime value in the...
April 26, 2013 at 3:15 pm
Here is a new query with two CTEs: the first finds all the ancestors of the selected client; the second CTE finds all the descendants of the top ancestor in...
April 26, 2013 at 9:55 am
First, let me point out that I understand "Link_Client_ID" to mean "the client of the current person" and not the other way around. In other words the first row of...
April 26, 2013 at 8:37 am
You really only need one CTE to rank the data, and then in the main query use a combination of aggregate functions and CASE statements to pivot the results into...
April 25, 2013 at 12:38 pm
I made the following tweaks to your CTE to give what I hope is a better result:
1. Fixed the main problem, which was that the anchor member of the "child"...
April 25, 2013 at 8:45 am
sdhanpaul,
The problem with the "group by" approach you propose is that it defines a duplicate row as that shares values in all the columns Student AND IDNo AND Tel3 AND...
April 24, 2013 at 8:05 pm
I've continued to scratch my head over this one, and I think I have a better solution now. What was troubling me is the fact that there is no good...
April 24, 2013 at 10:06 am
Sergiy,
I apologize for overlooking that detail of your script. Your script does identify the names with a duplicate entry by isolating the "known" ID values from the "unknown" ID values;...
April 24, 2013 at 7:18 am
After reading through the thread, I see that none of the solutions offered thus far have recognized the necessity of treating the rows with a known IDNo differently than the...
April 23, 2013 at 9:34 pm
I read the thread from your original post, and so far the emphasis has been on finding alternatives to LEFT and RIGHT, but your original question was just about the...
April 23, 2013 at 8:16 am
I think I finally figured out why it is acceptible to use the surrogate key for the many-to-many relationship between dimensions like my dimNames and dimAddresses dimensions. It is because...
November 9, 2012 at 10:25 am
That is not unlike how the many-to-many relationship is handled in the OLTP database from which I am pulling the data. In this approach every time a new Type 2...
November 8, 2012 at 9:17 am
I'm not sure how a factless fact table would differ from a snowflake dimension in terms of the actual table structure. But even if I pursue this approach, I am...
November 8, 2012 at 7:18 am
Viewing 15 posts - 106 through 120 (of 134 total)