Mac software to open a 16GB SQL file?

2

Possible Duplicate:
VERY large text files and Snow Leopard
Open massive file on Mac?

I have a 16GB sql database backup I have just taken, what software can I open it with for Mac?

I have tried TextMate, but that just fails completely by just opening a blank page and not attempting to open it. Any software will do (raw text/UI).

Tom

Posted 2009-11-14T10:53:28.177

Reputation:

Question was closed 2012-10-17T20:31:53.653

Answers

6

Assuming the SQL file was not created on that Mac, and depending on what you want to do with its data: just install the database software on that Mac, and import it into that new database?

Arjan

Posted 2009-11-14T10:53:28.177

Reputation: 29 084

4

There's a Vim plugin that allows it to open large files.

Then you could either go with the CLI version already installed or use MacVim.

Loïc Wolff

Posted 2009-11-14T10:53:28.177

Reputation: 1 947

3

How about:

less file.sql

from a terminal window? You can also use grep, etc.

Note that you can't edit with less. For navigating the file you can use arrow keys, space to scroll to the next page, b to go back one page. With / you can enter a search and then use n and N to jump between results, and finally press q to exit. Starting with less -S file.sql doesn't wrap lines and might be useful for SQL files with really long lines. All commands and options are explained in less' man page.

ChrisInEdmonton

Posted 2009-11-14T10:53:28.177

Reputation: 8 110

3

HexFiend is the best application I've found for extremely large files as it does not try to store the entire file in memory. While more of a hex editor than a text editor it may be more than workable given that it works very, very quickly.

Chealion

Posted 2009-11-14T10:53:28.177

Reputation: 22 932

Good and super quick, if you can afford to work without line breaks. – Fabien Snauwaert – 2017-07-06T20:19:39.843

1

BBEdit can probably handle it (so should TextWrangler), but unless you really need to get inside and make some changes to the data, re-importing into the proper database management software is going to be your best bet.

Hasaan Chop

Posted 2009-11-14T10:53:28.177

Reputation: 4 224

In my experience TextWrangler (free) can handle large files much better than TextMate, but I haven't opened anything like 16GB with it. – donut – 2009-11-16T02:40:48.767

0

Terminal -> 'vi'

romant

Posted 2009-11-14T10:53:28.177

Reputation: 1 071