Professional Web Applications Themes

onload/onunload all tables EXCEPT ones specified - Informix

Hi all, We have a database that contains 700 tables which we backup and restore monthly using onunload and onload commands. That database contains one table which is rather large (a LOB table) which is NOT required for monthly reporting in the restored area. I know that you can use onunload and specify tables to be backed up, but is there a way to specify tables that are NOT to be backed up? For example, this will only backup the mydb:images table: onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace mydb:images But if I wanted all tables except mydb:images ...

  1. #1

    Default onload/onunload all tables EXCEPT ones specified

    Hi all,

    We have a database that contains 700 tables which we backup and
    restore monthly using onunload and onload commands. That database
    contains one table which is rather large (a LOB table) which is NOT
    required for monthly reporting in the restored area.

    I know that you can use onunload and specify tables to be backed up,
    but is there a way to specify tables that are NOT to be backed up? For
    example, this will only backup the mydb:images table:

    onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace mydb:images

    But if I wanted all tables except mydb:images is there a "not"
    feature? Example:

    onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace !mydb:images

    Maybe wishful thinking so I don't have to list 699 tables so I don't
    back up the one I don't want...

    Thx

    Steve
    Steve N. Guest

  2. #2

    Default Re: onload/onunload all tables EXCEPT ones specified

    You could move the images table to it's own dbspace but I haven't
    used onload/onunload for a while.

    "Steve N." wrote:
    >
    > Hi all,
    >
    > We have a database that contains 700 tables which we backup and
    > restore monthly using onunload and onload commands. That database
    > contains one table which is rather large (a LOB table) which is NOT
    > required for monthly reporting in the restored area.
    >
    > I know that you can use onunload and specify tables to be backed up,
    > but is there a way to specify tables that are NOT to be backed up? For
    > example, this will only backup the mydb:images table:
    >
    > onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace mydb:images
    >
    > But if I wanted all tables except mydb:images is there a "not"
    > feature? Example:
    >
    > onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace !mydb:images
    >
    > Maybe wishful thinking so I don't have to list 699 tables so I don't
    > back up the one I don't want...
    >
    > Thx
    >
    > Steve
    --
    Paul Watson #
    Oninit Ltd # Growing old is mandatory
    Tel: +44 1436 672201 # Growing up is optional
    Fax: +44 1436 678693 #
    Mob: +44 7818 003457 #
    [url]www.oninit.com[/url] #
    Paul Watson Guest

  3. #3

    Default Re: onload/onunload all tables EXCEPT ones specified


    U can write some small script like this, u have to make a file with list
    of tables not to be included

    ( notincludelist.txt in the example)

    ---------------------------
    #/bin/ksh
    isql dbname<<!
    unload to list.out select tabname from systables where tabid> 99;
    !

    sed "s/|$//" list.out |while read rec
    do
    grep -wq ${rec} notincludelist.txt
    if [ $? -ne 0 ]
    then

    onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace mydb:${rec}

    fi
    done
    -----------------------------

    Rgds
    Preetinder
    Steve N. wrote:
    >Hi all,
    >
    >We have a database that contains 700 tables which we backup and
    >restore monthly using onunload and onload commands. That database
    >contains one table which is rather large (a LOB table) which is NOT
    >required for monthly reporting in the restored area.
    >
    >I know that you can use onunload and specify tables to be backed up,
    >but is there a way to specify tables that are NOT to be backed up? For
    >example, this will only backup the mydb:images table:
    >
    > onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace mydb:images
    >
    >But if I wanted all tables except mydb:images is there a "not"
    >feature? Example:
    >
    > onunload -t /dev/rmt0 -b 16 -s 4000000 -d myspace !mydb:images
    >
    >Maybe wishful thinking so I don't have to list 699 tables so I don't
    >back up the one I don't want...
    >
    >Thx
    >
    >Steve
    >
    >
    >
    sending to informix-list
    preetinder dhaliwal Guest

Similar Threads

  1. Why no onLoad or onUnload on _root?
    By Carl Fink webforumsuser@macromedia.com in forum Macromedia Flash Actionscript
    Replies: 0
    Last Post: January 28th, 08:01 PM
  2. loadMovie and onLoad
    By Brajeshwar in forum Macromedia Flash Actionscript
    Replies: 1
    Last Post: January 13th, 12:58 AM
  3. Onunload & onload question
    By Matthew Tan in forum Informix
    Replies: 3
    Last Post: October 22nd, 07:33 AM
  4. onload/onopen
    By zack in forum Microsoft Access
    Replies: 0
    Last Post: July 30th, 06:07 PM
  5. onunload event
    By RobGT in forum Macromedia Dreamweaver
    Replies: 1
    Last Post: July 10th, 01:17 PM

Bookmarks

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139