Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Formatting Dump information into compatible input commands - Help!

Formatting Dump information into compatible input commands - Help!

Formatting Dump information into compatible input commands - Help!


I am rebuilding a system and all I have is the php files and an old dump.

Unfortunately the dump file data is not in a compatible format for my database to accept it as a copy and paste.

I don't want to have to manually input all of the data again.

Is there any way I can get the data into a new data base easily?

If I cut and paste what's in the dump, I get a syntax error at the first digit.

Here's an example of the data I need to get in (from the old dump):

3    IT Department    t    2003-11-18 19:30:56.806108    2004-01-26 16:42:32.330953    f    2003-11-18 19:30:56.806108
2    HR    t    2003-11-18 19:30:53.85686    2004-01-29 14:45:38.020966    f    2003-11-18 19:30:53.85686
4    Sales    t    2003-11-18 19:30:59.353416    2004-01-29 14:45:46.591106    f    2003-11-18 19:30:59.353416
1    Marketing    t    2003-11-18 16:56:02.292023    2004-01-29 14:45:52.831915    f    2003-11-18 16:56:02.292023
5    Service    t    2003-11-19 12:11:19.993368    2004-01-29 14:46:00.140934    f    2003-11-19 12:11:19.993368
6    Corporate    t    2003-11-19 12:12:18.193393    2004-01-29 14:46:16.300815    f    2003-11-19 12:12:18.193393

Any ideas?

Thanks a lot in advance.


RE: Formatting Dump information into compatible input commands - Help!

using the console program psql - usually is enough (if no large objects are used)

psql DB_NAME < dump.sql

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close