Re: [GNC-dev] Find customer/vendor by name
Steve Brown <[email protected]> Mon, 8 May 2023 16:59:08 -0400
| Newsgroups | gmane.comp.gnome.apps.gnucash.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi Derek, On 5/8/2023 4:27 PM, Derek Atkins wrote: > HI, > > On Mon, May 8, 2023 4:16 pm, Steve Brown wrote: >> Hi Derek, >> >> On 5/8/2023 3:49 PM, Derek Atkins wrote: >>> Steve, >>> >>> On Mon, May 8, 2023 3:36 pm, Steve Brown wrote: >>>> There is currently code to find both by ID in gncIDSearch. >>>> >>>> Is there a simple way to search by name other than cloning the ID >>>> search code and changing ID to name? >>> You can Find by Company Name, Customer ID, Billing Contact, or Shipping >>> Contact. Which "Name" are you wanting to search for? >> I want to retrieve the vendor by VENDOR_NAME and customer by >> CUSTOMER_NAME in order to get their ID. >> >> I'm converting Quickbook transactions and need to create invoices and >> bills. For that I need customer and vendor ID's but only have the names >> in the transaction file. > There is already code to search for the CUSTOMER_NAME, at least the > standard Business -> Customer -> Find Customer dialog. Just select > "Company Name" and it will search on the CUSTOMER_NAME field. So just use > the drop-down to select "Company Name" and you'll search on what you want. Sorry I wasn't clear. I'm using the Python bindings, not the gui. I'm looking for something analogous to book.BillLookupByID() and book.InvoiceLookupByID for name. Steve