column order in csv export file

A place for users and developers of the Xataface to discuss and receive support.

column order in csv export file

Postby dynamic » Sat Jan 26, 2013 11:54 am

Hello,

I use export csv option but column order from csv file is different from what I set in fields.ini .
I speak about fields from "LEFT JOIN"

class tables_men_intreport {
<------><------>
function __sql__(){
<------>return "SELECT men_intreport.*,.
<------><------> men_zone.men_zone_name, men_uap.men_uap_name,
<------><------>FROM men_intreport LEFT JOIN men_zone ON men_zone_id = men_intreport_zone.
<------><------><------><------> LEFT JOIN men_uap ON men_uap_id = men_intreport_uap;
I define order in fields.ini to put [men_zone_name], [men_uap_name] at beginning in "list" and "new record", and it is ok.
But in csv file this columns are at the end. How can solve this problem.

Thanks a lot,
Dan
dynamic
 
Posts: 3
Joined: Thu Jan 17, 2013 2:35 pm

Re: column order in csv export file

Postby shannah » Mon Jan 28, 2013 9:25 am

If you use the "order" directive in the fields.ini file it should be obeyed by the export_csv option:

e.g.

Code: Select all
[myfield]
   order=2

[myfieldbefore]
    order=1


Steve
--
Steve Hannah
@shannah78 (on twitter)
sjhannah.com blog
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm


Return to Xataface Users

Who is online

Users browsing this forum: Bing [Bot] and 1 guest

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved