the details:
informix se v4.00
sco unix v3.2v4 (for what its worth)
i accidentally deleted the tablename.idx file, although the
tablename.dat file is still there. is there a way to re-create
the .idx?? i have tried CHECK TABLE, REPAIR TABLE,
but no luck.
please e-mail response to me.
thanks
-k
> oops! i hammered an .idx file while trying to "fix" an indexing
> problem with one of the tables in my system. yes, i know that it
> says practically everywhere in the manuals not to do this, but i
> figured if it was hosed already, what could it hurt. so, while i sit
> here listening to my multiple tape backup set whir, i figured i'd
> also ask the experts.
The experts are all on leave, so you'll have to make do with me...
Right:
1. Create a table (newtable)which is an exact duplicate of your
damaged table (badtable), including all indexes.
2. Copy the newtable_xxx.idx to badtable_xxx.idx.
3. bcheck -y badtable*.dat
Voila. Quicker than restoring a backup. (If it works). :-)
HTH.
--
Ciao,
Billy
I'd be in favour of apathy, but I just couldn't be bothered...
You have to create the file before attempting a repair.
If that still doesn't work, then restore the old .idx file then run a
repair.
Hope that helps,
--
Mark.
+-------------------------------------------------------------------------+
|Mark D. Stock - The West Solutions Group http://www.west.co.za |
| The Informix FAQ is at http://www.iiug.org |
|mailto:ma...@west.co.za +------------------------------------------------+
|Tel: +27 11 803 2151 |If it doesn't work... force it! |
|Fax: +27 11 803 2189 |If it breaks... it needed replacing anyway! |
|Cell: +27 83 250 2325 |Well, that's how I code anyway! |
+------------------------+------------------------------------------------+
______________________________ Reply Separator
_________________________________
}Subject: re-creating .idx file
}Author: The Mail Room, Inc.::(THMLRI) at ~FABRIK
}Date: 12/27/96 8:06 AM
}
}
}From: Kevin P.
}Date: Fri, Dec 27, 1996 8:06 AM
}Subject: re-creating .idx file
}To: informix-list; Susik Lee
}oops! i hammered an .idx file while trying to "fix" an indexing
}problem with one of the tables in my system. yes, i know that
}it says practically everywhere in the manuals not to do this,
}but i figured if it was hosed already, what could it hurt. so,
}while i sit here listening to my multiple tape backup set whir,
}i figured i'd also ask the experts.
}
}the details:
}
}informix se v4.00
}sco unix v3.2v4 (for what its worth)
}
}i accidentally deleted the tablename.idx file, although the
}tablename.dat file is still there. is there a way to re-create
}the .idx?? i have tried CHECK TABLE, REPAIR TABLE,
}but no luck.
}
}please e-mail response to me.
}
}kpav...@themailroom.com
}
}thanks
}-k
}
}----------
}Received: from rmy.rmy.emory.edu by portia.fabrik.com
} with SMTP (Fabrik F07.0-000)
} id SINN.5...@portia.fabrik.com ; Fri, 27 Dec 1996 09:30:47 -0800
}Received: (from ilist@localhost) by rmy.rmy.emory.edu (8.7.1/8.7.1) id MAA28645
}
}for susi...@uica.com; Fri, 27 Dec 1996 12:31:15 -0500 (EST)
}From: "Kevin P." <kpav...@themailroom.com>
}Message-Id: <01bbf40f$fc49c380$04d0...@tosheeba.themailroom.com>
}Subject: re-creating .idx file
}Date: 27 Dec 1996 16:06:58 GMT
}Reply-To: "Kevin P." <kpav...@themailroom.com>
}Organization: The Mail Room, Inc.
}Sender: informix-...@rmy.emory.edu
}To: inform...@rmy.emory.edu
}X-Informix-List-To: susi...@uica.com
}X-Informix-List-Id: <news.32017>
}
}----------
}
JLG
26#e#Susik_Lee_at_United#u#Group#c##c#25#e#PC_CCMailSusik Lee
<@MAIL.FABRIK.COM> wrote in article <5a8qj9$r...@cssun.mathcs.emory.edu>...
> I'm not sure this will work or not:
> - copy idx file from one of other table where there is no index.
> - go into dbaccess or isql, than try to create index
>
> Susik
>
>
> ______________________________ Reply Separator
> _________________________________
> }Subject: re-creating .idx file
> }Author: The Mail Room, Inc.::(THMLRI) at ~FABRIK
> }Date: 12/27/96 8:06 AM
> }
> }
> }From: Kevin P.
> }Date: Fri, Dec 27, 1996 8:06 AM
> }Subject: re-creating .idx file
> }To: informix-list; Susik Lee
> }oops! i hammered an .idx file while trying to "fix" an indexing
<Stuff Removed>
> bi...@west.co.za ("Billy Wheeler") wrote in article
<5a153n$c...@cssun.mathcs.emory.edu>...
> On 27 Dec 96 at 16:06, Kevin P. wrote:
> > oops! i hammered an .idx file while trying to "fix" an indexing
> > problem with one of the tables in my system. yes, i know that it
> > says practically everywhere in the manuals not to do this, but i
> > figured if it was hosed already, what could it hurt. so, while i sit
> > here listening to my multiple tape backup set whir, i figured i'd
> > also ask the experts.
>oops! i hammered an .idx file while trying to "fix" an indexing
>problem with one of the tables in my system. yes, i know that
>it says practically everywhere in the manuals not to do this,
>but i figured if it was hosed already, what could it hurt. so,
>while i sit here listening to my multiple tape backup set whir,
>i figured i'd also ask the experts.
>the details:
>informix se v4.00
>sco unix v3.2v4 (for what its worth)
>i accidentally deleted the tablename.idx file, although the
>tablename.dat file is still there. is there a way to re-create
>the .idx?? i have tried CHECK TABLE, REPAIR TABLE,
>but no luck.
Excuse me, but can't you just "touch <filename>.idx" and then run a
bcheck -s? Since the bcheck -s doesn't even *try* to read the existing
.idx (it just renames it to *.IDX) that *should* do it.