Viewing 15 posts - 1,246 through 1,260 (of 2,171 total)
OP (Ted Montoya) wrote 9/26/2007 10:04 PM that datatype is DECIMAL(5, 4).
All values I tested my code with works...
October 9, 2007 at 1:06 am
SELECT SUM(Col1), COUNT(Col1), COUNT(*) FROM Table1
WHERE Col2 = 'qwerty'
October 9, 2007 at 12:23 am
DECLARE@original DECIMAL(10, 5)
SET@original = 1078.734
SELECT@original,
REPLACE(REPLACE(REPLACE(RTRIM(REPLACE(REPLACE(STR(@Original, 15, 5), ' ', '#'), '0', ' ')), ' ', '0'), '#', ''), '.', '')
October 8, 2007 at 9:16 am
Here is a starter how to remove tags in a text
October 8, 2007 at 3:40 am
COUNT needs to scan the whole table.
Try this!
IF EXISTS (SELECT * FROM Performance.dbo.gChangedCUSIPs WHERE CUSIPKey = @vchVAGK + @vchPAC)
SET @bLookForChangedCUSIPs = 1
ELSE
SET @bLookForChangedCUSIPs = 0
October 8, 2007 at 2:49 am
Or you can use this, with space instead of backslash
October 7, 2007 at 12:11 pm
Answered here http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=90392
October 7, 2007 at 12:09 pm
Lowell's suggestion will work as long as there are only two levels of accounts.
This will traverse complete tree hierarchy
-- Prepare sample data
DECLARE @Accounts TABLE (AccountNumber CHAR(11), ParentAccountNumber CHAR(11))
INSERT @Accounts
SELECT...
October 4, 2007 at 2:31 am
Change your TEXT parameter to the new VARCHAR(max).
October 4, 2007 at 12:12 am
October 4, 2007 at 12:11 am
Read about "CAST & CONVERT" in Books Online.
October 3, 2007 at 11:45 pm
SELECTlb.Uid2,
lb.InvalidFlag
FROMtb_LeadBox AS lb
INNER JOINtb_DncNat AS dn ON dn.Dnc_Phone = lb.HomePhone
LEFT JOINtb_LB_SourceCode AS lbsc ON lbsc.SourceCode = lb.SourceCode
AND lbsc.Nat_DNC = 1
WHERElb.InvalidFlag IN (0, 7)
AND lbsc.SourceCode IS NULL
October 3, 2007 at 9:44 am
I think he mean TOTAL length for all 8 nvarchar columns.
SELECT TOP 1 WITH TIES PkCol, cl
FROM (
SELECT PkCol, DATALENGTH(Col1) + DATALENGTH(Col2) + DATALENGTH(Col3) + DATALENGTH(Col4) + DATALENGTH(Col5) + DATALENGTH(Col6)...
October 3, 2007 at 7:18 am
Viewing 15 posts - 1,246 through 1,260 (of 2,171 total)