You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cayenne.apache.org by GitBox <gi...@apache.org> on 2022/09/22 15:08:30 UTC

[GitHub] [cayenne] stariy95 opened a new pull request, #521: CAY-2759 Add utility methods to the SELF property

stariy95 opened a new pull request, #521:
URL: https://github.com/apache/cayenne/pull/521

   Here are some usage examples of the methods added:
   ```java
   // query() method to create ObjectSelect
   List<Artist> artistList = Artist.SELF.query().select(context);
   // same with a where clause
   Artist artistById = Artist.SELF.query(Artist.SELF.eqId(1)).selectOne(context);
   // shortcut for a EXISTS/NOT EXISTS subquery 
   long count = Artist.SELF.query(Painting.SELF.notExists(Painting.TO_ARTIST.eq(Artist.SELF.enclosing()))).selectCount(context);
   // column select
   List<String> names = Artist.SELF.columnQuery(Artist.ARTIST_NAME).select(context);
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cayenne.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [cayenne] stariy95 merged pull request #521: CAY-2759 Add utility methods to the SELF property

Posted by GitBox <gi...@apache.org>.
stariy95 merged PR #521:
URL: https://github.com/apache/cayenne/pull/521


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cayenne.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org