List:General Discussion« Previous MessageNext Message »
From:Kim Christensen Date:April 11 2006 10:33am
Subject:Re: A complex JOIN scenario
View as plain text  
> > Note that my example is not a realy result set, it's only here to show
> > you what kind of query I'm trying to build!
>
> Yes, that I understand. But WHAT is your current data in both tables
> from which you can/should derive your wanted resultset?

invoice_archive:
+------------+----------+--------------------+
| invoice_id | order_id | invoice_journal_id |
+------------+----------+--------------------+
|       1062 |     1035 |                  6 |
|       1063 |     1036 |                  6 |
|       1064 |     1037 |                  8 |
+------------+----------+--------------------+

invoice:
+------------+----------+-------------+-------------------+---------------+
| invoice_id | order_id | customer_id | invoice_timestamp | invoice_total |
+------------+----------+-------------+-------------------+---------------+
|       1065 |     1038 |          63 | 1144744655        | 777           |
+------------+----------+-------------+-------------------+---------------+

I hope this helps, sorry for being short on information but I haven't
really woken up properly yet. More coffee..

--
Kim Christensen
kim.christensen@stripped
Thread
A complex JOIN scenarioKim Christensen11 Apr
  • Re: A complex JOIN scenarioMartijn Tonies11 Apr
    • Re: A complex JOIN scenarioKim Christensen11 Apr
  • Re: A complex JOIN scenarioMartijn Tonies11 Apr
    • Re: A complex JOIN scenarioKim Christensen11 Apr
  • Index merge optimization (with OR) and table joinsStuart Brooks11 Apr
    • Re: Index merge optimization (with OR) and table joinssheeri kritzer4 May
      • Re: Index merge optimization (with OR) and table joinssheeri kritzer4 May
  • Re: A complex JOIN scenarioMartijn Tonies11 Apr
    • Re: A complex JOIN scenarioKim Christensen11 Apr
  • Re: A complex JOIN scenarioSantino11 Apr
  • Re: Index merge optimization (with OR) and table joinsStuart Brooks23 May
Re: A complex JOIN scenarioKim Christensen11 Apr
  • Innodb import tuning on Sun T2000Russell Horn7 Jul