Viewing 15 posts - 451 through 465 (of 712 total)
if you want the result like this
TranIDCode
201205AMDDOH
201206IXJRMI
then the query should be
select TranID , OriginCode + DestinationCode 'Code' from #Test
if this is not as per your output post a detailed explaination.
August 20, 2012 at 4:25 am
--begin tran
use master
declare @DB varchar(50)
select @DB = 'DB_Name'
CREATE TABLE #TMPFIXEDDRIVES (
DRIVE CHAR(1),
MBFREE INT)
INSERT INTO #TMPFIXEDDRIVES
EXEC xp_FIXEDDRIVES
CREATE TABLE #TMPSPACEUSED...
August 20, 2012 at 3:09 am
i go with suresh.
August 20, 2012 at 2:06 am
select convert(varchar,date_time,101), sum([Database Size in(MB)]) 'DB_Size inMB', [DB Name]
from #t1
group by convert(varchar,date_time,101),[DB Name]
order by convert(varchar,date_time,101)
try this.
August 20, 2012 at 2:00 am
SET NOCOUNT ON
DECLARE @hr int
DECLARE @fso int
DECLARE @drive char(1)
DECLARE @odrive int
DECLARE @TotalSize varchar(20) DECLARE @MB Numeric ; SET @MB = 1048576
CREATE TABLE #drives (drive char(1) PRIMARY KEY, FreeSpace int NULL,...
August 17, 2012 at 8:10 am
alternatively restart the agent using services.msc
check the sql error log and windows security log and post the errors if you found any after you access configuration manager.
August 17, 2012 at 6:55 am
select distinct @@servername, convert(varchar,a.backup_start_date,101) 'Date', a.database_name 'DB Name',
convert(decimal(7,2),round(sum(b.file_size/1024/1024/1024),3)) as 'Database Size in(GB)'
frommsdb..backupset a
inner join msdb..backupfile b on a.backup_set_id = b.backup_set_id
whereconvert(varchar,a.backup_start_date,101) = convert(varchar,getdate(),101)
and a.database_name in ( select name from...
August 17, 2012 at 6:44 am
Hello,
database_name is a nvarchar, how can you pass it to SUM?
alter the query.
August 17, 2012 at 6:09 am
what about management studio connection?
is Windows Management Instrumentation service running?
August 17, 2012 at 4:14 am
pawana.paul (8/16/2012)2. Limit size of Job History Log (Log Size in rows and rows per job) is set to max 999999.
If you set Log Size in rows and rows per...
August 17, 2012 at 3:00 am
Thanks joy,
just a doubt will the service packs changing the build dates?
August 17, 2012 at 2:44 am
Scott,
it is giving '2011-09-24 00:00:00.000' still not correct, we have installed it on august/september 2007 after that no re install /rebuild.
August 16, 2012 at 9:51 am
one of our server is 4/8/2003 9:13:36 AM but sql 2005 not released in 2003 , may be this is master db for 2005 build date.
August 16, 2012 at 9:23 am
why are you shrinking the DB which will cause the log to grow and index will be defragmented
so you have to do reindexing after that which will again grow...
August 14, 2012 at 7:27 am
Suri, this is not a local forum. you may not get appropriate answers/delayed answers.
check with your friends/local search engines.
August 13, 2012 at 6:24 am
Viewing 15 posts - 451 through 465 (of 712 total)