[wellylug] more on sql script
Rimu Atkinson
rimu1 at ihug.co.nz
Wed Nov 28 13:01:03 NZDT 2007
select distinct
E Chalaron wrote:
> Hi there
>
> Following my previous email regarding Mysql.
> Thanks to your various replies I have found several commands to provide
> me with data in an ordered way.
>
> I still have a problem. Some lines in the result are redundant.
> It is probably a pitfall for beginners in Mysql but can't find a solution.
>
> Here is my command (I am using the database from Streber a project
> management web interface):
>
> select strebproject.name, strebtask.name, strebtask.date_closed,
> strebtask.time_released \
> INTO OUTFILE '/data/data_test4.csv' FIELDS TERMINATED BY ',' ENCLOSED BY
> '"' LINES TERMINATED BY '\n' \
> from strebtask inner join strebproject \
> on strebtask.date_start = strebproject.date_start \
> where strebtask.name="14 day update" \
> order by strebproject.name asc;
>
>
> and here is the result :
> "test" appears several times and "Test Edouard" only once.. "test"
> should appear once as "Test Edouard"
>
> RESULTS :
>
> "test","14 day update","0000-00-00","0000-00-00 00:00:00"
> "test","14 day update","0000-00-00","0000-00-00 00:00:00"
> "test","14 day update","0000-00-00","0000-00-00 00:00:00"
> "Test Edouard","14 day update","0000-00-00","0000-00-00 00:00:00"
> "test file for dates","14 day update ","0000-00-00","0000-00-00 00:00:00"
> "test file for dates","14 day update","0000-00-00","0000-00-00 00:00:00"
>
>
> Thanks a lot for any help
> E
>
>
>
--
Email rimu1 at ihug.co.nz or rimuatkinson at gmail.com
Phone (04) 381 4827 or 021 232 1297
Skype rimu123
MSN rimuatkinson at msn.com
ICQ 60417596
Yahoo rimu_atkinson
http://rimu.geek.nz/
More information about the wellylug
mailing list