public static String getKeyQuery ( String queryString , String name ) { Matcher m = FROM_PATTERN . matcher ( queryString ) ; if ( m . find ( ) ) { StringBuilder sb = new StringBuilder ( "SELECT " ) ; sb . append ( getAlias ( queryString ) ) ; sb . append ( "." ) ; sb . append ( name ) ; sb . append ( " " ) ; sb . append ( m . group ( ) ) ; return sb . toString ( ) ; } return null ; }
Gets Query String for selecting primary keys