ho un problema
ho queste 2 tabelle
codice:create table if not exists pesci( id int(4), cat_id int(4) references categoria(cat_id), sottcat_id int(4) references sottocat(sottcat_id), aff_attribute int(4), affss_attribute int(4), nome text, descr text, prezzo char(8), datat char(30), primary key(id,sottcat_id,sottocat_id) ); create table if not exists rettili( id int(4), cat_id int(4) references categoria(cat_id), sottcat_id int(4) references sottocat(sottcat_id), aff_attribute int(4), affss_attribute int(4), nome text, descr text, prezzo char(8), datat char(30), primary key(id,sottcat_id,cat_id) );
se voglio fare una select e ottenere un unica tabella con tutti i valori che hanno affss_attribute='1', mi compare una tabella che sembra un prodotti di tabella...
questa la mia vecchia query
select pesci.nome,pesci.descr,pesci.prezzo,rettili.nome,r ettili,descr,rettili.prezzo,pesci.affss_attribute, rettili.affss_attribute
from rettili,pesci
where pesci.affss_attribute='1' and rettili.affss_attribute='1';
![]()

Rispondi quotando