Viewing 15 posts - 3,541 through 3,555 (of 5,504 total)
Joe Celko (5/12/2010)
REPLACE('I', '',
REPLACE('N', '',
REPLACE('P', '',
REPLACE('B', '',
REPLACE ( 'W', '', mutli_race_code),
),),),)...
May 12, 2010 at 12:30 pm
Maybe the reason you didn't get any reply yet is the way you posted your question.
There are some people around (including myself) that prefer to have ready to use sample...
May 12, 2010 at 10:34 am
samtrenchard (5/12/2010)
No sample data, no attempts to solve so far. This is still at the theoretical stage - essentially how do you calculate a moving (sliding) period aggregate !
Answering using...
May 12, 2010 at 10:08 am
the recursice CTE apporach is one possible solution. But as soon as there is a larger data volume to deal with, the quirky update is the better choice (from...
May 12, 2010 at 9:58 am
What's still missing is your expected result set based on your sample data.
Your reference to your first post won't help here since there is no way to tell whether you...
May 12, 2010 at 9:55 am
CirquedeSQLeil (5/11/2010)
lmu92 (5/11/2010)
CirquedeSQLeil (5/11/2010)
...As for the select top 1 *, the application may be doing that in order to populate a data grid with the column names.
...
If that's the only...
May 11, 2010 at 4:52 pm
CirquedeSQLeil (5/11/2010)
...As for the select top 1 *, the application may be doing that in order to populate a data grid with the column names.
...
If that's the only purpose of...
May 11, 2010 at 4:41 pm
The big question is: TOP 1 ordered by what column?
You should figure out what criteria will define the order to select top 1 and add those as an ORDER BY...
May 11, 2010 at 4:36 pm
a few things I noticed:
If the columns from_date and to_date contain date values, you should store them as datetime data, not as int.
Based on your description it's unclear how @date,...
May 11, 2010 at 4:16 pm
sohairzaki (5/11/2010)
where shall i use the crossapplythanks a lot
Use it like the sample I posted in one of your other threads ("Node.value and insert the result to an existing table").
The...
May 11, 2010 at 3:49 pm
Actually replacing a c.u.r.s.o.r. with a loop is like choosing pest over cholera...
Based on what you describe you don't need a RBAR solution.
May 11, 2010 at 2:07 pm
My I ask you again to run the code you provided to genarate the test data?
Strong hint (among others):
You have the following statement in your code
INSERT INTO [FIB].[dbo].[HHSReportsData]
...
May 11, 2010 at 1:56 pm
Please try to run the code you provided to generate the sample data. It won't run...
I don't mind adding a few comment marks or removing commas. But at least the...
May 11, 2010 at 1:19 pm
Two more things I'd like to know:
1) what is your expected result based on your sample data? and
2) What have you tried so far?
May 11, 2010 at 11:51 am
Since this is your third thread regarding this issue I recommend you include the reference to thos threads so you wouldn't have to deal with solutions that would not consider...
May 11, 2010 at 11:48 am
Viewing 15 posts - 3,541 through 3,555 (of 5,504 total)