Viewing 15 posts - 3,616 through 3,630 (of 4,085 total)
Ninja's_RGR'us (9/20/2011)
Nice use of a short-circuit!Then you just have to find a way to remove the rtrim in the where clause and this then has a chance to fly!
Isn't the...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 20, 2011 at 3:11 pm
Try the following code based on your original. All I did was move the reference to the new value table into a correlated subquery.
CREATE FUNCTION [dbo].[fn_Get_NewValuetbl]
...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 20, 2011 at 2:54 pm
Your function is doing a partial cross join. If you pass in the parameter "ABC" it will return "ABC" for every single value that you have in your new...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 20, 2011 at 2:35 pm
You've been around long enough to know that you should provide sample data and expected results.
It would also help if you provided the query where you are calling the function....
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 20, 2011 at 2:17 pm
hiyusuf (9/19/2011)
Dear All,I am creating a report of State wise Article Price for all states of India.
You should be doing this in SSRS (or whatever reporting software you are...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 20, 2011 at 11:12 am
kramaswamy (9/15/2011)
Didn't know that - personally never used the SSIS store for packages, always deployed mine by using DTEXEC. Good to know. Can you update them the same way?
I wouldn't....
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 15, 2011 at 8:43 am
dougb 34607 (9/15/2011)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 15, 2011 at 8:30 am
I think that you're approaching this backwards. Instead of starting from the filename and getting the file that matches it, you should start from the file and get the...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 15, 2011 at 8:13 am
kramaswamy (9/15/2011)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 15, 2011 at 7:50 am
Narud (9/14/2011)
Maybe the DISTINCT clause could be useful in this case.
This would require that all records with the same CaseID and Date have exactly the same ProviderCode (PRV_ID) and TypeServiceCode...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 14, 2011 at 1:38 pm
You can use a CROSS APPLY.
SELECT ColMultiple, ColD/ColMultiple as ColAverage
FROM tblCustomer
CROSS APPLY (
SELECT ColA*ColB*ColC as ColMultiple
...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 13, 2011 at 1:17 pm
If you don't supply a time, it defaults to midnight (00:00:00.000). So the datetime that your comparing to is '2011-05-31 00:00:00.000' which is less than the datetime on the...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 13, 2011 at 6:53 am
I still think that CROSS APPLY is going to be your better solution, but, again, without sample data there is no way to test the code. Based on Phil's...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 12, 2011 at 3:00 pm
Without sample data it's difficult to say what the best approach is, but there are two general approaches: Row_Number() or CROSS/OUTER APPLY. If you want tested code, you...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 9, 2011 at 1:46 pm
If you have a set number of emails, wouldn't it be easier to do this in a Derived Column Transformation?
I suspect that the Derived Column Transformation may also be more...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
September 9, 2011 at 12:30 pm
Viewing 15 posts - 3,616 through 3,630 (of 4,085 total)