code: @SafeVarargs
      public final <T> Optional<T> findFirst(final Class<T> targetClass, final String sql, Object... parameters) {
          final DataSet rs = query(targetClass, sql, 0, 1, parameters);
  
          return N.isNullOrEmpty(rs) ? (Optional<T>) Optional.empty() : Optional.of(rs.getRow(targetClass, 0));
      }
docs: Just fetch the result in the 1st row. {@code null} is returned if no result is found. This method will try to
  convert the column values to the type of mapping entity property if the mapping entity property is not assignable
  from the column value.
  
  Remember to add {@code limit} condition if big result will be returned by the query.
  
  @param targetClass an entity class with getter/setter methods.
  @param sql set <code>offset</code> and <code>limit</code> in sql with format:
  <li><code>SELECT * FROM account where id = ? LIMIT <i>offsetValue</i>, <i>limitValue</i></code></li>
  <br>or limit only:</br>
  <li><code>SELECT * FROM account where id = ? LIMIT <i>limitValue</i></code></li>
  @param parameters A Object Array/List, and Map/Entity with getter/setter methods for parameterized sql with named parameters
  @return