Viewing 15 posts - 736 through 750 (of 1,957 total)
I am not at my desk, so cannot check but thoughts are:
Use an xml schema to define the data type?
Format the value in a VARCHAR variable instead of a decimal,...
September 25, 2013 at 12:34 pm
How about the path to RS.exe - is that right?
September 25, 2013 at 12:29 pm
declare @dob datetime,@now date
set @dob='1 jan 2012'
set @now = '31 dec 2012'
select
datepart(year,@now) - datepart(year,@dob)
+
case
when dateadd(day
...
September 20, 2013 at 6:15 pm
Hi Brandie,
Your first two updates need the "Extract" column, which is not covered by the filtered indexes, so a decision has to be made whether to index seek and key...
September 20, 2013 at 5:30 pm
The problem is that you can't have negative lengths or positions and you will get those, so you need to protect against them.
Try this:
select
-- uncomment the following...
September 20, 2013 at 11:02 am
I think that, if you took the time to learn what the code you already have is doing, you would have your answer.
PATINDEX tells you the location or index of...
September 19, 2013 at 4:34 pm
Ooh if kludges are what we want here, I love kludges...
select months.val
from some_table
cross apply (
select 1 ,GBAN01/100 union all
select 2 ,GBAN02/100 union all
select 3 ,GBAN03/100 union all
select 4 ,GBAN04/100...
September 19, 2013 at 4:29 pm
There is no need for all those joins.
select e.MSKEY
, max(case when e.ATTRNAME='FNAME' then e.AVALUE end) AS FNAME
, max(case when e.ATTRNAME='MNAME' then e.AVALUE end) AS MNAME
, max(case when e.ATTRNAME='LNAME' then e.AVALUE...
September 16, 2013 at 5:13 pm
Hi,
Please read this article and post some sample data that can easily be used.
You will get help much quicker with this information.
September 9, 2013 at 3:46 pm
Hi, this should help:
CREATE FUNCTION FormatLakhCrores (@number SQL_VARIANT,@conversion smallint)
RETURNS TABLE
WITH SCHEMABINDING
AS
--= Function to format a number using the Lakh/Crores style
--= Written 06 Sept 2013 Mister Magoo
--= Permission granted for public...
September 5, 2013 at 6:28 pm
Surely this is a case for validation at the front end?
There always used to be a rule that applications validate input...
September 3, 2013 at 4:22 pm
Most likely answer seems to me to be that your data item is not a date, so using date formatting options won't work...
September 3, 2013 at 4:16 pm
pietlinden (8/12/2013)
August 12, 2013 at 5:31 pm
Interesting, but is it practical to try and protect every table in this way?
In case you are interested - and I am not suggesting this is any better, but for...
August 9, 2013 at 1:16 pm
Jason,
Simply putting "from sys.columns" after it should be enough to get a plan.
And, no I don't have an authoritative source - boy I wish I did, so for now...
August 9, 2013 at 11:51 am
Viewing 15 posts - 736 through 750 (of 1,957 total)