Viewing 15 posts - 2,026 through 2,040 (of 2,646 total)
CREATE FUNCTION ConvertToBase64
(
@P1 varchar(100)
)
RETURNS nvarchar(100)
AS
BEGIN
DECLARE @ResultVar nvarchar(MAX)
SELECT @ResultVar=CAST(N'' AS XML).value('xs:base64Binary(xs:hexBinary(sql:column("P1")))', 'VARCHAR(MAX)')
FROM (SELECT CONVERT(VARBINARY(MAX),@P1) [P1]) X
RETURN...
November 12, 2018 at 10:10 am
Xml data type methods are not supported in computed column definitions.
Create a scalar user-defined function to wrap the method invocation.
November 12, 2018 at 9:57 am
SELECT RIGHT('00000000000000000' + REPLACE(CONVERT(varchar,CONVERT(decimal(13,4),@myDecimal)),'.',''),13)November 12, 2018 at 9:41 am
--DECLARE @myDecimal as decimal(4,1) = 4.5
--DECLARE @myDecimal as decimal(13,4) = 38
DECLARE @myDecimal as decimal(13,4) = 56.78
SELECT RIGHT('00000000000000000' + REPLACE(CONVERT(varchar,@myDecimal),'.',''),13)
November 12, 2018 at 9:24 am
An alternative is to use windowed functions:;WITH l AS
(
SELECT l.Dealer, l.DescR, l.Attempt, l.Ref, l.Salute,l.Updated_Date, l.Cont_date, l.Compcode,
ROW_NUMBER()...
November 12, 2018 at 9:15 am
There is a problem with the way your script inserts the dates. It just enters them as text so they are not sortable by date, the same applies to the...
November 12, 2018 at 9:05 am
The Primary Field Shows...
| 177460285 |
this query:
ACCESSPANE.PRIMARYIP,
CAST(ROUND( (cast(cast(dbo.ACCESSPANE.PRIMARYIP as binary(4)) as bigint) /...
November 12, 2018 at 4:06 am
November 11, 2018 at 6:20 pm
November 11, 2018 at 5:17 pm
November 11, 2018 at 11:29 am
November 9, 2018 at 12:27 pm
"i am seeing if table a has a certain row from certain b"
select *
from a
where exists(select *
...
November 9, 2018 at 12:13 pm
Specifies that the query is optimized for fast retrieval...
November 9, 2018 at 11:59 am
TOP 1 is...
November 9, 2018 at 8:43 am
Alternatives are:select * from myTable x
where x.Description like '%text%'
select * from myTable x
where PATINDEX('%text%',x.Description)>0
select * from myTable x
where CHARINDEX('text',x.Description)>0
I doubt...
November 9, 2018 at 7:14 am
Viewing 15 posts - 2,026 through 2,040 (of 2,646 total)