protected void validateFeature( Feature feature, SqlParserPos context) { if (feature.equals(disabledFeature)) { CalciteException ex = new CalciteException( FEATURE_DISABLED, null); if (context == null) { throw ex; } throw new CalciteContextException( "location", ex, context.getLineNum(), context.getColumnNum(), context.getEndLineNum(), context.getEndColumnNum()); } } }
null, errorMatches( new CalciteException("Empty result of JSON_VALUE function is not " + "allowed", null))); assertJsonValueAny( null, errorMatches( new CalciteException("Empty result of JSON_VALUE function is not " + "allowed", null))); assertJsonValueAny( null, errorMatches( new CalciteException("Strict jsonpath mode requires scalar value, " + "and the actual value is: '[]'", null)));
protected void validateFeature( Feature feature, SqlParserPos context) { if (feature.equals(disabledFeature)) { CalciteException ex = new CalciteException( FEATURE_DISABLED, null); if (context == null) { throw ex; } throw new CalciteContextException( "location", ex, context.getLineNum(), context.getColumnNum(), context.getEndLineNum(), context.getEndColumnNum()); } } }
SqlJsonQueryEmptyOrErrorBehavior.NULL, errorMatches( new CalciteException("Empty result of JSON_QUERY function is not " + "allowed", null))); SqlJsonQueryEmptyOrErrorBehavior.NULL, errorMatches( new CalciteException("Empty result of JSON_QUERY function is not " + "allowed", null))); assertJsonQuery( SqlJsonQueryEmptyOrErrorBehavior.ERROR, errorMatches( new CalciteException("Strict jsonpath mode requires array or " + "object value, and the actual value is: 'bar'", null)));