hi

it is very simple in php




    $query = 'SELECT *
    FROM table
    WHERE somefield = "'.$somevalue.'"
    ORDER BY somefield
    ';
        $mysql_result = mysql_query($query, $mysql_link);


    while($row = mysql_fetch_array($mysql_result))
{

$output .=
"\"$row["somefield"]\"\t\"$row["some_other_field"]\"\t\"$row["yetnother_fiel
d"]\"\t" ;


}// end while


    (not tested)


\t is the tab character

hth

Peter


-----------------------------------------------
Excellence in internet and open source software
-----------------------------------------------
Sunmaia
Birmingham
UK
www.sunmaia.net
tel. 0121-242-1473
International +44-121-242-1473
-----------------------------------------------




-----Original Message-----
From: Catalist Solutions [mailto:[EMAIL PROTECTED]
Sent: 04 February 2004 09:04
To: MySQL Mailing List
Subject: Downloading/Exporting delimited text files


Hi,

I hope someone can point us in the right direction.

We have built up a database of over 2 million part numbers applicable to the
horticultural machinery trade.

This is held on our website in a MySQL database and subscribers can do all
sorts of searches by manufacturer or part number or description, whatever.
It all works well having used Dreamweaver to generate the various web pages.

We now want to allow them to download a tab delimited text file for
importing into their own standard spreadsheets and databases (unlikely to be
MySQL).

We are struggling with this as there don't appear to be any Macromedia
Extensions which will allow us to do this within DreamWeaver.

Will we have to use PHP in order to achieve this task? PHPAdmin allows us to
do the above but we don't want our subscribers to use PHPAdmin, we want them
to just click buttons on a web page.

Any comments anyone?

Thanks and regards,

Bernard Norrie
Catalist Solutions Ltd.




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to