|
Group: Forum Members
Posts: 524,
Visits: 30K
|
Hey Sam
I'm sure you'll get other answers but just to get you started, think in terms of creating a view in SQL much as you would for a report, denormalizing the data so you have a record for each line item that includes invoice and customer data. Do your search against this as all the fields will be available. Return a set that is a select distinct for the customer, if that's what your looking for and let the user select from that to return one customer record. Greg or Ivan will probably best advise as to where to intervene to return only one row for each distinct customer for the final selection but you can get started by just returning the entire result as that will work too, just will have multiple rows possibly for the chosen customer based on an invoice data range, for example.
|