Viewing 15 posts - 1,951 through 1,965 (of 3,011 total)
Thanks for a chance to pad my posts some more.
I'm currently holding the 61st spot on the all time posts lists, so maybe this will put me over the top...
March 13, 2009 at 8:12 am
frankivey (3/12/2009)
March 12, 2009 at 6:09 pm
I made that last post to try to see why my prior post was not showing on my Recent Posts display.
Neither showed up, so I am not sure what was...
March 12, 2009 at 5:42 pm
You should read about the restore command in SQL Server 2005 Books Online.
http://msdn.microsoft.com/en-us/library/ms178615(SQL.90).aspx
March 12, 2009 at 12:14 pm
It would be much simpler if you just stored that actual start and end times as datetime datatypes as the actual start datetime and end datetime. Then is is...
March 12, 2009 at 10:37 am
Another variation from Lynn's version:
;with
a1 as (
select 1 as N union all select 1 union all select 1 union all select 1 union all
select 1 union all select 1 union...
March 12, 2009 at 9:18 am
When you do a backup with append, you are writing a new backup set to the end of the same file. When you restored you probably did not specify...
March 12, 2009 at 8:09 am
I think this illustrates the problem with the OP picking the best solution:
http://www.sqlservercentral.com/Forums/Topic673876-1291-1.aspx
The best solution is debateable in this situation, but I doubt the OP was really able to judge...
March 12, 2009 at 7:38 am
AFIFM (3/12/2009)
...The sample code by Michael also does the job nicely except that it will only generates 5 characters string and I need 64 chracters.
I just assumed you would be...
March 12, 2009 at 7:29 am
The account that xp_cmdshell is running under will have to have permission to delete the file.
xp_cmdshell runs under the SQL Server service account if it is executed by a sysadmin...
March 11, 2009 at 10:46 pm
select
Random_String =
substring(x,(abs(checksum(newid()))%36)+1,1)+
substring(x,(abs(checksum(newid()))%36)+1,1)+
substring(x,(abs(checksum(newid()))%36)+1,1)+
substring(x,(abs(checksum(newid()))%36)+1,1)+
/* and so on for as many characters as needed */
substring(x,(abs(checksum(newid()))%36)+1,1)
from
(select x='0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ') a
Results: ...
March 11, 2009 at 10:42 pm
Bruce W Cassidy (3/11/2009)
March 11, 2009 at 2:53 pm
The last one (For rounding off to the nearest minute) does not work for the entire range of datetime. I have posted a more general method below.
print 'Limited start...
March 11, 2009 at 1:23 pm
Luke L (3/11/2009)
March 11, 2009 at 12:17 pm
Viewing 15 posts - 1,951 through 1,965 (of 3,011 total)