Re: Line replace



DarkBlue <nomail@xxxxxxxxxxx> writes:
> The markers are just there to have a static way to find the line
> after the marker, which is the one which might have to be changed.

OK, why don't you store those changing lines in the database?

Can you arrange for those changeable lines to be fixed length, i.e.
by padding with spaces or something? If you can, then you could just
overwrite them in place. Use flock or fcntl (Un*x) or the comparable
Windows locking primitives to make sure other processes don't update
the file simultaneously.
.



Relevant Pages

  • Network Device Inventory Database
    ... I am trying to create a database to keep track of static IP addresses ... This has also got to store the location of the device, ... when the max of Part 4 has been reached, and to get Part 4 to reset and start ... Prev by Date: ...
    (microsoft.public.access.tablesdbdesign)
  • web form state accross sessions
    ... Is there an easy way to store the values of a web form in to a database so ... Prev by Date: ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: PLEASE HELP ME , I am stuck!!!!
    ... What database was used to store all these data? ... Weka is one option but I would like to suggest you download Microsoft ... Prev by Date: ...
    (comp.databases.olap)
  • Re: Call sub or function using a string value for the name
    ... Yes, store the name of the required "Action" in the database, not the ... Michael ... Prev by Date: ...
    (microsoft.public.vb.general.discussion)
  • Re: Line replace
    ... why don't you store those changing lines in the database? ... the line after the marker... ... go to line after marker and replace that one with newlinetext ...
    (comp.lang.python)

Loading