Viewing 15 posts - 1 through 15 (of 35 total)
Thanks John
Yes that is correct I need time component as 00:00:00.000
Brij
July 4, 2006 at 3:58 am
Hope this helps..
Select * From Employee E1 Where
(N-1) = (Select Count(Distinct(E2.Salary)) From Employee E2 Where
E2.Salary > E1.Salary)
Brij
July 4, 2006 at 3:05 am
I am using aggregate functions to update the columns in the table, so I had to use Derived table from derived tables, something like this:
update a set a.col3 = c.col3
from...
Brij
July 4, 2006 at 2:52 am
Thanks you all..
Derived tables were the best solution..
Brij
July 4, 2006 at 2:48 am
Daizy
Further your query will subtract only 7 days from current datetime, so if query is run at 10AM, then you will not get the records till 10 AM.
thanks
Brij
June 14, 2006 at 6:08 am
is this from single table and do that table have date column?
Brij
June 14, 2006 at 2:38 am
Swathi, unfortunately you cannot pass array in SQL, however you can pass comma separated lists and then parse it.
There are many posts where you can search for those codes,...
Brij
June 2, 2006 at 4:23 am
instead do SET @VDNList = null.
this will also not add comma in front
Brij
June 1, 2006 at 8:16 am
Declare @VDNLIST Varchar(4000)
SELECT @VDNLIST = COALESCE(@VDNLIST + ', ', '') + vdn as 'VDN' FROM Table
WHERE type = '2B' and callcenter = 'Tulsa'
SELECT @VDNLIST
Brij
May 31, 2006 at 7:32 am
I got the same error and ran DBCC and error was fixed..
Run dbcc checkdb (DBNAME,repair_allow_data_loss)
few times..
hope this will help...
Brij
May 31, 2006 at 6:26 am
you can use Deleted table to get the the record that was updated and get all the feilds and insert them im table2.
like
Insert into Table2 Select * from deleted,...
Brij
May 31, 2006 at 5:24 am
use
select max(invoiceID), invoiceNumber
from table
group by invoiceNumber
Brij
May 30, 2006 at 7:58 am
I agree with you...
I normally use csv just for integer values, so that there is not much load or looking for special characters and all that.. csv is passed by...
Brij
May 30, 2006 at 4:59 am
Joe
What I meant was passing comma separated values in a parameter to insert those into multiple rows in a table, Where does this violate 1NF.
for eg:
Create Procedure myproc(@val1, @val2, @val3,...
Brij
May 30, 2006 at 4:45 am
Viewing 15 posts - 1 through 15 (of 35 total)