ormlite 多表联合查询

ormlite 多表联合查询


QueryBuilder shopBrandQueryBuilder = shopBrandDao.queryBuilder();
QueryBuilder shopQueryBuilder = shopDao.queryBuilder();

Where shopBrandWhere = shopBrandQueryBuilder.where();
shopBrandWhere .eq(ShopBrand.SHOP_NO, shopNo);

Where shopWhere = shopQueryBuilder.where();
shopWhere
.like(Shop.SHOP_CODE, "%" + serch + "%")
.or()
.like(Shop.SHOP_LNAME, "%" + serch + "%");

QueryBuilder resultQueryBuilder =          
shopBrandQueryBuilder
.join(shopQueryBuilder);
shopBrands=resultQueryBuilder.query();
上一篇:SharePoint 2013 列表多表联合查询


下一篇:多线程专题之线程死锁原因之谜