211655 Posted April 20, 2006 Posted April 20, 2006 Hi, Due to quickbooks limitations, I am starting to use Ideal COmputer Systems Accounting software. I need to export orders data into the CSV format. Below are the reuqirements they have. I am limited knowldge of php but I think i do understand that how i will do it but not the code. I will appreciate if someone can guide me. > The field definitions are: > > #1 Ordernumber > #2 Date > #3 Time > #4 First Name > #5 Last_Name > #6 Name on Card (usually just first name last name) > #7 Company > #8 email > #9 Billing Address line 1 > #10 Billing Address line 2 > #11 Billing City > #12 Billing State > #13 Billing Zip > #14 Billing Country > #15 Billing Phone > #16 Ship To First_Name > #17 Ship To Last_Name > #18 Ship To Name > #19 Ship To Company > #20 Ship To Address line 1 > #21 Ship To Address line 2 > #22 Ship To City > #23 Ship To State > #24 Ship To Zip > #25 Ship To Country > #26 Ship To Phone > #27 Card Type > #28 Card Number > #29 Exp Date mmyy > #30 Bank Name (optional) > #31 Gateway Auth Code (if using pmt gateway) > #32 AVS Code (if using pmt gateway) > #33 Transaction ID (if using pmt gateway) > #34 Order Special Instructions > #35 Comments > #36 Order Subtotal $ > #37 Order Tax $ > #38 Order Insurance $ > #39 Tax Exempt Message (out of state) > #40 Order Shipping Total > #41 Small Order Fee > #42 Discount Rate (if giving a discount on order) > #43 Discount Message > #44 COD Amount $ > #45 Order Grand Total $ > #46 Number of items in order > #47 Shipping Method > #48 Shipping Weight > #49 Coupon Code > #50 Order security message > #51 Order Surcharge Amount (not supported) > #52 Order Surcharge Something or other (not supported) > #53 Affiliate code > #54 Sentiment message > #55 Checkout form type used > #56 Card CVV value > #57 future > #58 future > #59 future > #60 future > #61 future > #62 future > #63 future > #64 future > #65 future > After that, the items in the order start. Each item has a BEGIN_ITEM > field, then item data, the END_ITEM field. So having a look up, i think. I have to write a php code which will first read 2 tables: orders and orders_status_history. All the one line item data from orders and comments from order_status history will be read. then in the loop where I am writing the file, I will call 4 more sql statements for the order id and get sub total, tax, total, grand total from orders_total table. then next one is tricky. In this, i need a list of items ordered. i will use a while loop again and read the value of each item one by one from orders_products table and then end the loop. any other suggestions are welcome. I am also willing to pay someone via Paypal if they can help me out. email me at 211655(at)gmail.com. You can test create the solution if u have already and i can work with you. Thanks 211655 SEO Optimization Export Orders into CSV file
VPSsupport Posted April 20, 2006 Posted April 20, 2006 I would like something very similar to this Regards, Clive
211655 Posted April 21, 2006 Author Posted April 21, 2006 i scrambled some thoughts and came up with this quick and dirty file. works just fine for me. http://www.oscommerce.com/community/contributions,4181 211655 SEO Optimization Export Orders into CSV file
kyao888 Posted November 5, 2006 Posted November 5, 2006 i scrambled some thoughts and came up with this quick and dirty file. works just fine for me. http://www.oscommerce.com/community/contributions,4181 How do you add column names on the very first row?
Recommended Posts
Archived
This topic is now archived and is closed to further replies.