Viewing 15 posts - 31 through 45 (of 94 total)
how do you delete a post?
March 26, 2010 at 12:19 am
btw guys, how do you know if someone replied to you in a forum or posted something in the same forum you posted? I mean do you have any notifications...
March 26, 2010 at 12:15 am
Hi there,
I just changed your where clause...
I hope this helps ^__^
Declare @name varchar(100)
set @name = 'count'
SELECT c1
FROM mytbl2
WHERE c1 LIKE '%' + @name + '%'
AND c1 NOT LIKE '%[A-Z]'...
March 26, 2010 at 12:11 am
Hi there,
^__^ I hope this helps
DECLARE @tbl TABLE (TransactionID INT,Code CHAR(3),Num INT, DateTimeReceived DATETIME)
INSERT INTO @tbl
SELECTpkTransactionID
--,ComponentText
,LEFT(ComponentText,3)
,RIGHT(ComponentText,LEN(ComponentText)-3)
,DateTimeReceived
FROM ##Temp1
SELECTDISTINCT
tot.TransactionID
,tot.NumAS 'TOT'
,UniqueEnvs = gbx.Num + iex.Num + unk.Num
,gbx.NumAS 'GBX'
,iex.NumAS 'IEX'
,unk.NumAS 'UNK'
,tot.DateTimeReceived
FROM @tbl tot
INNER JOIN...
March 25, 2010 at 9:09 pm
Hi there,
Just wanna try out my solution ^__^
SELECT @date=t1.[date]
FROM @Table1 t1
INNER JOIN @Table2 t2 ON (t1.[date]=t2.[date])
GROUP BY t1.[date]
HAVING COUNT(name)=(
SELECT COUNT(DISTINCT Name)
FROM @Table1 t1
INNER JOIN @Table2 t2 ON (t1.[date]=t2.[date]))
March 25, 2010 at 8:37 pm
I agree with Eric
SELECT CAST((RAND()*1000000000) AS INT)
since you said no "-"
but if it includes dashes like lowell's example, thi is my code
DECLARE @i INT
SET @i=1
DECLARE @tbl TABLE (SSN NVARCHAR(11))
WHILE @i<=1000
BEGIN
INSERT...
March 25, 2010 at 3:17 am
😀 Man, I love you guys!!!
Thanks!
:)Hi sqlizer, i tried the rightclick then open as administrator... :w00t:IT WORKED ^__^ Wohooo!!! Thanks!!!:hehe:
Thanks Guys!!! ^__^
:w00t:Merry Christmas and a Happy New year to you...
December 25, 2008 at 9:47 pm
:)Hi there,
Uhmmmm... Why not use one table instead of 44?
Example:
Hope this helps... ^__^
Create Table MyTable
(
IDINTIDENTITYNOT NULL,
Item1VARCHAR(MAX)NOT NULL,
Item2VARCHAR(MAX)NOT NULL,
DateDATETIMENOT NULL
)
--Now, if we want to view a particular Year and Month, We...
October 13, 2008 at 6:47 pm
Hi there,
Hope this helps...
First lets create some sample data...
CREATE TABLE SprocTable
(
IDINTIDENTITY,
SprocVARCHAR(MAX)
)
GO
CREATE PROC USP_Hi
AS
SELECT 'Hi'
RETURN
GO
CREATE PROC USP_Hello
AS
SELECT 'Hello'
RETURN
GO
INSERT INTO SprocTable
SELECT 'USP_Hi'
UNION
SELECT 'USP_Hello'
SELECT * FROM SprocTable
like so...
Now lets execute our sproc
DECLARE @sproc...
October 6, 2008 at 2:56 am
Hi there,
Hope this helps... By the way, is the excel sample data from Excel or from SQL?
If from SQL, try this one...
DECLARE @EndDate DATETIME, @StartDate DATETIME
SELECT @StartDate=[Column_A] WHERE [Column_C]='S'
SELECT @EndDate=[Column_A]...
September 23, 2008 at 7:08 pm
Hi there,
I think your problem is here
EXEC dbo.eProcedure @value1,@eValue OUTPUT
Can you post the code that you used for this sproc. Its either the parameters for @Value in...
September 23, 2008 at 6:43 pm
:DLOL
:PI forgot to explain...
:)The Stored procedure expects inputs for ALL its parameters unless they have DEFAULT values...
:w00t:By the way, it's best to use my first example, It easier to do...
September 22, 2008 at 2:29 am
Hi there,
Hope this helps
DECLARE
@taxCode varchar(100),
@Qty numeric(19,6),
@Price numeric(19,6),
@dis numeric(19,6),
@AssessableValue numeric(19,6)
SELECT
@taxCode = '123',
@Qty = '123'),
@Price = '123',
@dis = '123',
@AssessableValue = '123'
EXEC tax
@taxCode varchar(100),
@Qty numeric(19,6),
@Price numeric(19,6),
@dis numeric(19,6),
@AssessableValue numeric(19,6)
-- OR
EXEC tax
@taxCode = '123',
@Qty =...
September 22, 2008 at 2:28 am
:DHi there,
:PSorry this came late, I have no network connection last friday and I'm ofline during saturdays and sundays...
:hehe:Anyway, regarding your question... Are you talking about this one?
WHERE CONVERT(VARCHAR(MAX),GETDATE(),103)=CONVERT(VARCHAR(MAX),Date,103)
You see...
September 21, 2008 at 8:09 pm
Hi there,
Hi there,
This isn't the exact answert but i hope it helps
For 8 working hours per day...
SELECT DATEDIFF(mm,GETDATE(),'12/12/12') * 8
If your talking about Monday-Friday only, that's a different query
It would...
September 21, 2008 at 6:54 pm
Viewing 15 posts - 31 through 45 (of 94 total)