FTP to SQL

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
themcnabs
Forum Newbie
Posts: 3
Joined: Wed Mar 26, 2008 4:42 pm

FTP to SQL

Post by themcnabs »

I am in need of setting up a script to automatically download a file via FTP and import it into a SQL database. Can someone help me with this?
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: FTP to SQL

Post by Christopher »

For FTP there are many classes around that help with this, or:

http://us.php.net/manual/en/ref.ftp.php

To help you import into a database we would need to know the format of the data. Look into LOAD DATA INFILE.
(#10850)
themcnabs
Forum Newbie
Posts: 3
Joined: Wed Mar 26, 2008 4:42 pm

Re: FTP to SQL

Post by themcnabs »

The ftp looks pretty straight forward. Can this PHP script be put into a cron job?

I found the syntax for the "LOAD DATA INFILE", but where do you implement it?
themcnabs
Forum Newbie
Posts: 3
Joined: Wed Mar 26, 2008 4:42 pm

Re: FTP to SQL

Post by themcnabs »

This is now looking like it is going to be too complicated for me. Is there anyone I could hire to do this for me?
Post Reply