PDOCrud Join operation

PDOCrud supports both left join and inner join operation. If you want to apply master, detail table operation where master table contains single record and details table contains multiple records, use LEFT JOIN else INNER JOIN.


Example of inner join 1
Example of inner join 2
  
                            $pdocrud = new PDOCrud();
                            $pdocrud->crudTableCol(array("first_name","last_name","user_name","gender"));
                            $pdocrud->joinTable("user_meta", "users.user_id = user_meta.user_id", "LEFT JOIN");
                            echo $pdocrud->dbTable("users")->render();
                            

Users

Showing 1 to 10 of 104 entries

# User id First name Last name User name Gender Actions
1 30 yemqHDGbASghVu hcWntOcErdNAcklhyj QIuDjsqpMkLGUDESEm 0
2 31 diVUWhZW piuyVsUF JASmEYjXcs WxpTqMlVOTn
3 32 LapEdGLoP LyVHqKxdGnkQxm poFoKHHbATkCMoxDtD qVtoIpYabtpwOBnTT
4 33 fHqVKpLtpYxPS AOhlDipUucpIf TcrsnckMMP txdqycWcG
5 34 MxRquwgsmVilLm rcRLwHqVYs KoTPzWLZpiSHMRwEn ocNprqVBzYz
6 35 PgVZDurVKuPuXxDqEg lRDKlBQjqxD izFoeaACEWURJvYJH 0
7 36 ATqxtCjdpXW cbRfPSvUTLB GGjRxyHDB YpiduCUWXIEUunGwG
8 37 dadzwvHDxrdtrfRZ kOTyaRxIAv BVugOgrVFSxpkPDO tBfvzBdDyqq
9 38 sfPcxGdtkyXwm DjuOlMHQPIE tTEXNTWWXHhmpaNhm LSRscMXZBLongGZxnhh
10 39 GvSEsRTW IcPVOgrxNrcXbu dfNrCQeneSSjZJ RtkuYmJtLvmT
# User id First name Last name User name Gender Actions