Class JpqlLeftJoinSupport

java.lang.Object
io.jmix.aitools.dataload.execution.JpqlLeftJoinSupport

@Component("aitls_JpqlLeftJoinSupport") public class JpqlLeftJoinSupport extends Object
Narrows the left joins of a data-load query in their own on clause, so that a record hidden from the current user is joined as an absent one instead of removing the row. The public QueryTransformer can only add to the where, so this rewrites the parser's syntax tree.
  • Field Details

  • Constructor Details

    • JpqlLeftJoinSupport

      public JpqlLeftJoinSupport()
  • Method Details

    • rewrite

      public JpqlLeftJoinSupport.Rewrite rewrite(String jpql)
      Starts a rewrite of the query.
      Parameters:
      jpql - query text the JPQL parser can read
      Returns:
      the rewrite; its result is the query text with every change applied
      Throws:
      JPA2RecognitionException - if the JPQL parser cannot read the text