Solved

Large file ( about 7 g )

Posted on 2012-03-09
4
359 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
Comment Utility
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 91

Expert Comment

by:nobus
Comment Utility
0
 

Author Comment

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

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Suggested Solutions

Update 11/3/2014 - Although the below article will get you to relocate the WINSXS folder, Microsoft has finally released a utility to reduce the size of the WINSXS folder. For some reason, it's not that straightforward. It only works on Windows 2008…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …

772 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now