On Tue, Feb 04, 2003 at 21:00:47 -0500,
Dinesh V <dinesh(at)trailblazingsolutions(dot)com> wrote:
> Hello Folks,
>
> I have 7.3.1 running, and have an interesting SQL problem, please help.
> Consider an Invoice Table with columns
>
> InvoiceId
> ProductId
> Quantity
>
> Given a set of ProductId and Quantity, I need to find the InvoiceId that
> correspond to it. I can create a temp table with these 2 columns (ProductId
> and Quantity) if necessary.
Unless there is more to this problem, you can just do something like:
select InvoiceID from Invoice_table where
ProductID = 'XXX' and Quantity = 'YYY';