Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2007
    Posts
    3

    Unanswered: Database maintenance plan without using the wizard

    Hi everybody,
    I need a way to create a database maintenance plan in SQL Server 2000, without using the wizard. So, I am looking for a way to create this plan either using TSQL or (even better) using VB6 code (maybe by using SQLDMO library). I want the end-user of my vb6 application to decide for the options of the plan (like scheduling or backup directory). Does anybody have any sample vb6 code for doing this?
    Thanks in advance.

  2. #2
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    you can do all of this in T-SQL using the BACKUP command, DBCC CHECKDB and DBCC DBREINDEX. See BOL for details and command options. To allow users to configure options from the front end, you are going to have to use dynamic sql.
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •