On Thu, Dec 26, 2019 at 6:53 PM fmiser <fmiser@gmail.com> wrote: [snip]
Well, the current import script imports "inventory" for existing
"parts". Importing inventory means that it sets up the quantities and balance in the inventory account (for the parts specified) and sets up the desired COGS values.
I think you are saying that my idea of two-step would work. That is, use COPY parts FROM 'file.csv' DELIMITER ',' CSV HEADER;
to fill in most of the information, followed by a run of the inventory import script.
Yes. Exactly.
Then what about customers and vendors (contacts)? Is there a way to get 200 customers and 120 vendors in - again without adding them one at a time?
The existing import system doesn't have imports defined for customers and vendors. I can see why you would say that a straight CSV import into the tables might not be easy. I think it's actually not too much work with the following information:
[snip]
That looks doable. Not necessarily without risk of error, though... Hmm. Maybe a spreadsheet with one tab with all the data, and other tabs that pull info from the main one that can be exported as CSV as needed for each table.
That would work, except for the fact that the key that cross-references most of the tables is generated on import of the entity and entity_credit_account tables. If you export the imported information again and use that to tie the various CSVs together, that'd work. (Note that 'entity.control_code' and 'entity_credit_account.meta_number' are meant to be used as system-independent references; you could put a value in it that you generate in your CSV which you can use to lookup the internal 'id' number later).
Because a lot of this info is relational, it's a bit hard to import it in a CSV, is what I'm thinking. Formats like YAML, XML or JSON allow more hierarchical data to be specified. For customer import, I'm thinking that might work better. What would be your view on that?
The beauty of csv is I can use the power of a spreadsheet to build it. And I can use text tools to manipulate various outputs from the old SQL-Ledger - including copy/paste from the browser. I'm not familiar with YAML, but XML or JSON I guess could be built from a csv, but this is getting convoluted...
Fair enough. Let me know how you think we can best facilitate future users who want to initialize the system with costumers/vendors based on your experience once you're a bit more into the process. -- Bye, Erik. http://efficito.com -- Hosted accounting and ERP. Robust and Flexible. No vendor lock-in.