Viewing 15 posts - 61 through 75 (of 102 total)
I'm a little confused; is the code I supplied inadequate because it has 00 hours and indicates the zero for the tens in the minutes?
I'm taking it for granted that...
February 19, 2011 at 11:16 pm
Hi,
Your requirements aren't super clear, so perhaps I am not helping you here.
Here is a script showing how to input time, quite simply in to a demo table that has...
February 19, 2011 at 6:53 am
Hi,
My 2c...
1. I am concerned that varbinary(50) may not be sufficient storage space.
2. Depending on usage, you may want to check out FILESTREAM if you are using sql server 2008.
I...
February 19, 2011 at 6:33 am
Would I be correct in adding that NOT will void the use of an index, if one exists on the field - not SARGable.
And therefore opt instead for the inversion...
February 16, 2011 at 8:37 pm
Assuming the most simplest requirement, something like the following?
SELECT SUM(SUM(LEN(Field_A)) + SUM(LEN(Field_B)) + SUM(LEN(Field_C)))
FROM Table_X
February 14, 2011 at 11:31 pm
I googled 'sql server cte hierarchy tutorial' and came up with some results that would certainly help you. Failing that, typing 'WITH' into SSMS, highlighting it and pushing F1 (BOL),...
February 13, 2011 at 10:33 pm
Yeah, there doesnt seem to be a built-in way to produce ordinals.
I haven't run you function, but the logic didnt check out in my head; I may be wrong but...
February 12, 2011 at 2:44 am
First things that pop in to my head:
1. CTE to identify occurrences of the desired string part
2. Table valued function using the CTE and then using CROSS APPLY
Perhaps others have...
December 19, 2010 at 1:24 am
Try insert both results in to a table variable if UNION doesn't work.
November 29, 2010 at 12:10 am
What have you tried so far?
It is unlikely that you will be assisted here if your question seems like homework and your post doesn't follow the recommended criteria.
November 29, 2010 at 12:03 am
Now all that's left for you is to clean up the blood 😀
October 28, 2010 at 12:15 am
Ah... Found this one in some old code of mine too...
master.dbo.fn_varbintohexstr()
October 27, 2010 at 11:58 pm
Try:
-- Convert binary value in a variable to hexstring:
declare @hexbin varbinary(max);
set @hexbin = 0xabcedf012439;
select '0x' + cast('' as xml).value('xs:hexBinary(sql:variable("@hexbin") )', 'varchar(max)');
go
PS.
Have not tested this code
October 27, 2010 at 11:53 pm
Hi,
I would try Base64 => Varbinary => Hex
I don't think there is a direct conversion but I may be wrong.
Good luck!
October 27, 2010 at 11:05 pm
Sorry - Did not see
May 21, 2010 at 6:27 am
Viewing 15 posts - 61 through 75 (of 102 total)