SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Transaction Log Backup Script issues


Transaction Log Backup Script issues

Author
Message
SQL Galaxy
SQL Galaxy
SSCertifiable
SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)

Group: General Forum Members
Points: 6865 Visits: 3501
Declare @FileName varchar(255)
select @FileName = 'D:\BackupDB\Tlog\DVM_DB_Tlog' + substring(convert(varchar(50),getdate(),120),0,11)+'.TRN'
BACKUP LOG [DVM] TO DISK = @FileName WITH NOINIT , NOUNLOAD ,
NAME = N'DVM', NOSKIP , STATS = 10, NOFORMAT , NO_TRUNCATE

pls give me anybody, i need with time this script

for example
DVM_DB_Tlog 2008-09-26 16:50:28.TRN
steveb.
steveb.
SSChampion
SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)

Group: General Forum Members
Points: 10630 Visits: 7195
What is the problem you are having with it?
SQL Galaxy
SQL Galaxy
SSCertifiable
SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)

Group: General Forum Members
Points: 6865 Visits: 3501
TLog Backup has been taken with date, but i need date and time becuse all Tlog overwrite the same file.

as per script file format is
D:\BackupDB\Tlog\DVM_DB_Tlog 2008-09-26.TRN

I want with time as follows
D:\BackupDB\Tlog\DVM_DB_Tlog 2008-09-26 16:50:28.TRN
Buxton69-502449
Buxton69-502449
Mr or Mrs. 500
Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)Mr or Mrs. 500 (526 reputation)

Group: General Forum Members
Points: 526 Visits: 465
Try using this in part of your script, I don't think you can have a colon (: ) in the file name, that might be the reason it's not working, this should remove the : from the name:

LEFT(REPLACE(REPLACE(CONVERT(VARCHAR,GETDATE(), 120), ' ', '_'), ':', ''), 18)
Rajesh kasturi
Rajesh kasturi
SSC Eights!
SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)

Group: General Forum Members
Points: 899 Visits: 732
That is right file name can't have /\:*?"<>|.

Rajesh Kasturi
SQL Galaxy
SQL Galaxy
SSCertifiable
SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)

Group: General Forum Members
Points: 6865 Visits: 3501
Thanks for reply

i got file format with help of your script,

DVM_DB_Tlog2008-09-29_173509.TRN

.. its ok fine,
SQL Galaxy
SQL Galaxy
SSCertifiable
SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)SSCertifiable (6.9K reputation)

Group: General Forum Members
Points: 6865 Visits: 3501
hi,

could you give me details,

what is different between incremental backup & differential backup in sql server 2000?
Rajesh kasturi
Rajesh kasturi
SSC Eights!
SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)

Group: General Forum Members
Points: 899 Visits: 732
As you know we have 3 types of backups available in SQL Server
Full, Differential and Transactional

Incremental backup can be Differential or T-Log.

Rajesh Kasturi
Wildcat
Wildcat
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1251 Visits: 1444
ananda.murugesan (9/29/2008)

what is different between incremental backup & differential backup in sql server 2000?


SQL SERVER does not have incremental backup.

But, the Windows OS does have.Wink
Rajesh kasturi
Rajesh kasturi
SSC Eights!
SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)SSC Eights! (899 reputation)

Group: General Forum Members
Points: 899 Visits: 732
Hi Wildcat,
Could you please tell me what is meaning of incremental backup weather it is in OS or sql server.

Rajesh Kasturi
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search