Welcome! Log In Create A New Profile

Advanced

HreadNext while Reindexing

Posted by Harry 
Harry
HreadNext while Reindexing
September 30, 2008 01:09PM
Hi,

When we read a big file with ..

1 HReadfirst(HFFile,HFIndex)
2 While not Hout
3 message(HFFile.HFFileID)
4 loop
5 if HReadNext(HFFile,HFIndex) then
6 break
7 else
8 Error("Can not Read the Next record ")
9 multitask(100)
10 end
11 end

and while this process is run we start the reindexing of HFFILE then we get the error...
===========================================================
Error in Click Button69 process, line 5.
HReadNext function called.
Unable to read HFFile.NDX> file.

Technical Information

Project : rontgen

Dump error of module <WD100HF.DLL> <10.00Edh>.

- WL Call:
Processing <sysinlezen.Button69>, line <5>, thread <0>
Function <HReadNext>, syntax # <0>

- Level: fatal error (EL_FATAL)

- Error Code: 70150

- WD55 Error Code: 150

- No system error code

- No system error message

- What happened?
Unable to read HFFILE.NDX> file.

- Debug Information:
##(IXStream)-Handle=<00000154>##
##(IXStream)-bExact=<1>##
##(IXStream)-A lire=<41>, lu=<0>##
==============================================================

How to solve this in a neat way ????

Regards Harry
Fabrice Harari
Re: HreadNext while Reindexing
September 30, 2008 01:26PM
Hello Harry...

The first thing to say is that reindexing should be done ONLY when nobody is using the file because obvioulsy it has to recreate the index file....

So you should test that the files are not used by locking them before doing the reindaxtion...

best regards

Fabrice Harari
WinDev, WebDev, WinDev Mobile Video Courses
Harry
Re: HreadNext while Reindexing
September 30, 2008 01:36PM
Hello Fabrice,

Yes, i know that that is the best... but when you have more then 100 users it is not easy to get the file in exclusive use.

Other suggestions ???

Thanks for your reply.

Regards Harry
Fabrice Harari
Re: HreadNext while Reindexing
September 30, 2008 03:33PM
Hello Harry...

In winDev 12, you have the possibility to do a hot reindexing and your users will automatically be blocked with a message during that time... (see hindex help)

But I still thinks that reindexation should be done outside work hours each time it's possible

Best regards

Fabrice Harari
WinDe, WebDev, WinDev Mobile consulting
Al
Re: HreadNext while Reindexing
September 30, 2008 10:06PM
Hello Harry

I am interested in why you need to reindex.
In our experience (HF Classic) the indexes are remarkably stable and we can generally say that problems with indexes are due to hardware issues - power outs and nics. Indeed we often find that the Hubs and switches are forgotten about and left off the UPS and once connected to a UPS a lot of problems go away.

Are you having problems in general with indexes ?

Regards
Al
Georgio
Re: HreadNext while Reindexing
September 30, 2008 10:11PM
Hi Harry,

You run the risk of corrupting your index while other's are using the program. Fabrice is correct, it needs to be done when no user is accessing a file.

Approx. how many records are you talking about? Millions?

Georgio
Harry
Re: HreadNext while Reindexing
October 01, 2008 01:45PM
Hello Harry

I am interested in why you need to reindex.
In our experience (HF Classic) the indexes are remarkably stable and we can generally say that problems with indexes are due to hardware issues - power outs and nics. Indeed we often find that the Hubs and switches are forgotten about and left off the UPS and once connected to a UPS a lot of problems go away.

Hello Al,

It was not in our production system.
We just wanted to test it.

Regards Harry
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: