And if AdFind doesn't keep them in order, let me know as that would be a featur... Err I mean bug. For -csv and -oao options I maintain the order specified on purpose.
I can't speak to CSVDE and how it works, I actually have never looked at the source for that program. I expect you may be getting different orders based on the DC you are querying possibly. There is no guarantee on the order returned from the DCs so if you want that guarantee, the tool outputting the results has to be aware to do it. joe -- O'Reilly Active Directory Third Edition - http://www.joeware.net/win/ad3e.htm -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mike Newell Sent: Thursday, September 14, 2006 10:56 AM To: [email protected] Subject: RE: [ActiveDir] CSVDE Export Hey, Don't know why csvde would change the order but try adfind from www.joeware.net. So far for me, it's always kept the fields in the order that I list them in the query. Below gets just the user accounts in the OU. If you want everything in the OU remove the -f (&(objectcategory=person)) reference. adfind -csv -nodn -b OU=User Accounts,OU=Office,OU=Company,DC=abc,DC=defghi,DC=inet -f "(&(objectcategory=person))" name mail givenname sn userprincip alname physicaldeliveryofficename > filename.csv ________________________________________ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mark Parris Sent: Thursday, September 14, 2006 6:02 AM To: [email protected] Subject: [ActiveDir] CSVDE Export Morning, I am using csvde to create a CSV file for importing into another system and this runs (CRONS - say no more) on regular basis. the syntax is csvde -f accusers.csv -d "OU=User Accounts,OU=Office,OU=Company,DC=abc,DC=defghi,DC=inet" -l "name,mail,givenName,sn,userprincipalname,physicalDeliveryOfficeName" on occasions the fields come out as listed and other times they are in a different order. I would like them to be consistent at all times. Does anyone know why they shuffle? Am I missing a flag or is there a better utility to create CSV files many thanks mark This message and any attachments (the "Message") may contain confidential, proprietary and/or privileged information and are only for their intended recipient(s). If you are not the intended recipient, you should notify the sender and delete the Message. E-mail transmissions cannot be guaranteed to be secure or error-free. This Message is provided for information purposes and should not be construed as a solicitation or offer to buy or sell any securities or financial instruments, or to provide investment advice in any jurisdiction where the sender is not properly licensed or permitted to do so. This Message is subject to additional conditions and restrictions. Please read them here: http://legal.dimensional.com/email/ List info : http://www.activedir.org/List.aspx List FAQ : http://www.activedir.org/ListFAQ.aspx List archive: http://www.activedir.org/ml/threads.aspx List info : http://www.activedir.org/List.aspx List FAQ : http://www.activedir.org/ListFAQ.aspx List archive: http://www.activedir.org/ml/threads.aspx
