Viewing 15 posts - 16 through 30 (of 330 total)
Hey thats a good call made by shankar Openquery will let you to use join condition.
OPENQUERY can be referenced in the FROM clause of a query as if it...
April 28, 2011 at 7:58 am
Try
Select 'EN'+CONVERT(varchar,DATEPART(yy,getdate()))+
CONVERT(varchar,datepart(mm,getdate())) +
CONVERT(varchar,datepart(dd,getdate()))+
CONVERT(varchar,datepart(HH,getdate()))+
CONVERT(varchar,datepart(MI,getdate()))+
CONVERT(varchar,datepart(SS,getdate()))+
CONVERT(varchar,datepart(MS,getdate()))
this will never repeat unless you change server time.
April 27, 2011 at 7:06 am
Please don't cross post. It just wastes peoples time and fragments replies.
No replies to this thread please. Direct replies to: http://www.sqlservercentral.com/Forums/Topic1099236-391-1.aspx
April 27, 2011 at 4:49 am
SQLRNNR (4/26/2011)
with preprocess as (
Select internalid,txn.Terminal,txn.ActivityDate,datepart (hh,ActivityTime) As ActivityHour
FROM dbo.ABCD txn
WHERE ActivityDate >= '3/1/2011' AND ActivityDate < '4/1/2011'
)
select distinct Terminal,ActivityDate,ActivityHour
From preprocess
Where ActivityHour >= 23...
April 26, 2011 at 11:49 am
PSB (4/26/2011)
SELECT DISTINCT txn.Terminal,txn.ActivityDate,datepart (hh,ActivityTime) As H
FROM dbo.ABCD txn
WHERE ActivityDate >= '3/1/2011' AND ActivityDate < '4/1/2011'
AND datepart (hh,ActivityTime) <6 AND datepart (hh,ActivityTime) >= 23
Order...
April 26, 2011 at 11:34 am
Your question is not understandable what you are trying to do with this North_south and why not east_west.I am not sure for what you are looking for
declare @Temp table...
April 26, 2011 at 11:07 am
Raghavender (4/26/2011)
Hi All,We need to delete some millions of rows from a table.
And we need this should not affect transactional log file.
Is there a way to achieve this ?
What are...
April 26, 2011 at 5:47 am
Are you asking like this
declare @String varchar(1000)
select @String='nhtinhfsgjesalgjdmexSUM=190SUMdsfsdfsdfsdsdsdf'
Select SUBSTRING(@String, 1, CHARINDEX('SUM',@String)-1),REVERSE(SUBSTRING(REVERSE(@String), 1, CHARINDEX('MUS',REVERSE(@String))-1))
April 26, 2011 at 4:31 am
usharani.t (4/21/2011)
I write an stored procedure...the select statement returns more than one value.. how i assign that to a variable .. is it possible
What you are trying to do with...
April 21, 2011 at 5:23 am
Ali Tailor (4/20/2011)
HiWhat is mean by CDC table???:crying:
CDC is change data capture which a feature which was added in SQL 2008
Change data capture is designed to capture insert, update,...
April 20, 2011 at 3:39 am
Rog Saber (4/19/2011)
DECLARE @TempResults TABLE
(row_num smallint identity,
rate_split char(1),
...
April 19, 2011 at 10:47 am
Is this you are looking for
declare @test-2 table (Response_ID int, Company varchar(20),Amount decimal(18,2),Quarter tinyint,Year int)
Insert into @test-2
Select 1,'Company A', 100.00, 1, 2010
union all Select...
April 19, 2011 at 7:57 am
I have made a small change in the date field
Yours 19.04.2011and i have changed as 04/19/2011
declare @Temp table (Time_Stamp datetime ,Action_Code tinyint, Person_ID int)
Insert into @Temp
Select '04/19/2011 09:03:39', 1,...
April 19, 2011 at 7:28 am
Lynn Pettis (4/18/2011)
parthi-1705 (4/18/2011)
Lynn Pettis (4/18/2011)
select
'id: ' + id + ';' +
'name: ' + name + ';' +
...
April 18, 2011 at 11:07 am
Lynn Pettis (4/18/2011)
select
'id: ' + id + ';' +
'name: ' + name + ';' +
...
April 18, 2011 at 10:09 am
Viewing 15 posts - 16 through 30 (of 330 total)