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

    Unanswered: ingres commandline advice needed

    Hi all!
    I am new to Ingres DBMS and its commandline.
    I need to execute many times destroydb, followed by relocatedb (it is a routine job), so I think it's the case to put these two commands in a batch file. Does ingres offer anything like this? If yes, then, is there a way to give the -dbname of the relocatedb command as an argument to the batch file?
    I mean, I would ruther execute

    batfilename -dbname, than

    destroydb db1
    relocatedb dbname -new database db1.

    hope i made it clear enough,
    i would welcome any advice

  2. #2
    Join Date
    Nov 2007
    Both those commands are available at the command line, so writing a batch file is definitely possible. It sounds like you are running windows. I'll go ahead and write up a quick blog entry here with details, but you pretty much have what you need. The only additions should be:

    1. Don't use the "-" in the command line parameters
    2. Use the variable %1 to get the dbname inside your batchfile
    3. check the ERRORLEVEL variable for nonzero results and respond accordingly.

    You can find the details later today at

  3. #3
    Join Date
    Nov 2007

    Thank you

    Thank you so much, I will try right now. Best regards

Posting Permissions

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