Mi spiego:
Ho tre tabelle sullo stesso db, e devo prelevare le ultime cinque righe inserite, ordinate per timestamp, escludendo quelle con uno status=1.
ESEMPIO:
TAB 1:
id testo timestamp status
1 pippo 20070124230443 1
2 pluto 20070124220910 0
3 qui 20070124220233 0
4 quo 20070124215635 1
5 qua 20070124200443 0
TAB 2:
id testo timestamp status
1 xxxx 20070124220000 0
2 yyyy 20070124214522 0
3 www 20070124210233 1
4 qqqq 20070124200355 0
5 ssss 20070124190443 0
...
TAB 3:
id testo timestamp status
1 cccc 20070124235900 1
2 pippo 20070124232044 1
3 qqq 20070124210333 0
4 quo 20070124194623 0
5 qua 20070124182403 0
...
L'ordine che voglio è questo:
2 pluto 20070124230122 (da tab1)
3 qui 20070124220233 (da tab1)
1 xxxx 20070124220000 (da tab2)
2 yyyy 20070124214522 (da tab2)
3 qqq 20070124210333 (da tab3)
E' possibile creare una sola query ottenendo i dati voluti?
Spero di esser stato chiaro...
Grazie in anticipo.