Solved

Large file ( about 7 g )

Posted on 2012-03-09
4
386 Views
Last Modified: 2012-06-26
Hi, Experts -
I have a large file (about 7g) that I need to search for a text and replace.
How do I go about doing it thru windows commands. Addition to that - suggest a few good text editors for large files (e.g textpad won't work file of that size). I prefer to do it thru cmd window.

Thanks,
0
Comment
Question by:ivan_belal
4 Comments
 
LVL 5

Accepted Solution

by:
Jason Schlueter earned 500 total points
ID: 37703415
PowerShell should be able to handle something of that size but you will need to write the results to a second file.

Get-Content c:\hugefile1.txt
    | Foreach-Object {$_.Replace('thing to replace', 'what to replace it with')}
    | Set-Content c:\hugefile2.txt
0
 
LVL 92

Expert Comment

by:nobus
ID: 37704354
0
 

Author Comment

by:ivan_belal
ID: 37720241
PowerShell seemed to work, thanks.
Any other text editors able to handle large files (~7 gig) ?
0

Featured Post

Easy, flexible multimedia distribution & control

Coming soon!  Ideal for large-scale A/V applications, ATEN's VM3200 Modular Matrix Switch is an all-in-one solution that simplifies video wall integration. Easily customize display layouts to see what you want, how you want it in 4k.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Sometimes drives fill up and we don't know why.  If you don't understand the best way to use the tools available, you may end up being stumped as to why your drive says it's not full when you have no space left!  Here's how you can find out...
While rebooting windows server 2003 server , it's showing "active directory rebuilding indices please wait" at startup. It took a little while for this process to complete and once we logged on not all the services were started so another reboot is …
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question