I made a database "type" program a while back that can store upto 1 million records in a file as big as 2Gb. I use it for many things and it has worked very well so far.
What i am now doing is going back into the code and adding some new parts to it - one of the parts i'd like to add is the ability to delete a record within the file and move the other files up.
I tried the usual of seeking to the file to be deleted, loading all of the records after it into memory, truncate the file and then putting the records in memory back into the file.
Problem is that it uses a lot of memory and sometimes i get the "out of memory" message depending on what else i have running at the same time.
Anyone got a way to do the same thing, perhaps by using a temporary file, etc?