Results 1 to 4 of 4
  1. #1
    Affiliate/AM Moonlighter dflsports's Avatar
    Join Date
    January 17th, 2005
    Posts
    874
    Exporting MYSQL export query to a text file
    I need some assistance.

    I have some data in a MYSQL databases. I was to query the database like this (got this query using phpmyadmin)

    SELECT `merchant`, `name`, `description`, `image_url`, `buy_url`, `price`, `category`, `brand` FROM `products` WHERE `name` LIKE CONVERT(_utf8 '%searchterm%' USING latin1) COLLATE latin1_swedish_ci

    I would like to use php to query the mysql database and create a file in a directory on the server, like mysearchterm.csv

    I can export the query using phpmyadmin but I's love to be able to automate the process.

    Thanks!

  2. #2
    ABW Ambassador Snib's Avatar
    Join Date
    January 18th, 2005
    Location
    Virginia
    Posts
    5,303
    This can be done with PHP. I'd create an application that takes the search term, runs the query and writes the results to the file. It can be done with a form to input the search term and a bit of code to query the db and create the file.

    - Scott
    Hatred stirs up strife, But love covers all transgressions.

  3. #3
    Affiliate/AM Moonlighter dflsports's Avatar
    Join Date
    January 17th, 2005
    Posts
    874
    Thanks Snib, you answered my question creating more questions

  4. #4
    ABW Ambassador Snib's Avatar
    Join Date
    January 18th, 2005
    Location
    Virginia
    Posts
    5,303
    Quote Originally Posted by dflsports
    Thanks Snib, you answered my question creating more questions
    Well what questions do you have now? Maybe I can help.

    - Scott
    Hatred stirs up strife, But love covers all transgressions.

  5. Newsletter Signup

+ Reply to Thread

Similar Threads

  1. Exporting not working, New Column in Export also..
    By Georgie Peri in forum Google Affiliate Network - GAN
    Replies: 5
    Last Post: March 7th, 2012, 06:47 PM
  2. Need help with MySQL query
    By mobilebadboy in forum Programming / Datafeeds / Tools
    Replies: 3
    Last Post: January 17th, 2007, 03:00 AM
  3. Export Source File - Help!
    By blackgrape in forum WebMerge (Fourthworld.com)
    Replies: 6
    Last Post: August 19th, 2005, 02:32 PM
  4. Help please with mysql query
    By IGshop in forum Programming / Datafeeds / Tools
    Replies: 15
    Last Post: January 19th, 2004, 08:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •