Skip to content

[Bug] repeat function has hard limit 10000 #652

Description

@zhangxffff

Component Selection

  • Core Engine (Expression eval, Memory, Vector)
  • Connectors / File Formats (Hive, Parquet, etc.)
  • API / Bindings (Python, etc.)
  • Build
  • Other

Describe the Bug

org.apache.gluten.exception.GlutenException: Exception: BoltUserError
Error Source: USER
Error Code: INVALID_ARGUMENT
Reason: (10437 vs. 10000) Count argument of repeat function must be less than or equal to 10000
Retriable: False
Expression: count <= kMaxResultEntries
Context: array_repeat(get(n21_4, 0:INTEGER), coalesce(cast((get(n21_4, 1:INTEGER)) as INTEGER), 1:INTEGER))
Additional Context: Top-level Expression: concat_ws(,:VARCHAR, array_repeat(get(n21_4, 0:INTEGER), coalesce(cast((get(n21_4, 1:INTEGER)) as INTEGER), 1:INTEGER)))
Function: checkCount
File: /opt/tiger/compile_path/src/code.byted.org/olap/gluten/ep/bolt/bolt/functions/lib/Repeat.cpp
Line: 80

Reproduction Steps

select array_repeat(1, 20000);

Bolt Version / Commit ID

7f4e4f5

System Configuration

- **OS**: (e.g. Ubuntu 22.04, CentOS 7)
- **Compiler**: (e.g. GCC 11, Clang 14)
- **Build Type**: (Debug / Release / RelWithDebInfo)
- **CPU Arch**: (e.g. x86_64 AVX2, ARM64)
- **Framework**: (e.g. Spark 3.3, PrestoDB)

Logs / Stack Trace

Expected Behavior

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions