Hi jonni.
Now there is no error but there is not results
Here is a example:
my original query:
$this->db->select('*, ...... t_imm.tbds_destab_txt,sub_t_imm.tbds_destab_txt,.....');
$this->db->join('tbl_dati_sistema t_imm', 't_imm.tbds_keytab_txt = imm.aimm_tipologia_code and t_imm.tbds_tblname_txt = "TIP_IMMOB"', 'LEFT');
$this->db->join('tbl_dati_sistema sub_t_imm', 'sub_t_imm.tbds_keytab_txt = imm.aimm_tipologia_code and sub_t_imm.tbds_tblname_txt = "SUBTIP_IMMOB"', 'LEFT');
That work fine
This my crocery porting:
.
.
.
$crud->setPrimaryKey('tbds_destab_txt', 'tbl_dati_sistema');
$crud->setRelation('aimm_tipologia_code', 'tbl_dati_sistema', 'tbds_destab_txt', ['tbds_tblname_txt' => 'TIP_IMMOB']);
$crud->setRelation('aimm_subtipologia_code', 'tbl_dati_sistema', 'tbds_destab_txt', ['tbds_tblname_txt' => 'SUBTIP_IMMOB']);
.
.
.
Regards
Andrea