Skip to content

[fix](restore) Analyze idx meta in Olap Table after restore commit #51883

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: branch-2.1
Choose a base branch
from

Conversation

wyxxxcat
Copy link
Contributor

@wyxxxcat wyxxxcat commented Jun 18, 2025

reproduce: backup and restore Table or restart fe, then insert

before:

desc tbl all
*************************** 26. row ***************************
    IndexName: idx
IndexKeysType: AGG_KEYS
        Field: mv_date_format(hours_add(happen_time, 1), '%Y-%m-%d %H:00:00')
         Type: varchar(65533)
 InternalType: varchar(65533)
         Null: Yes
          Key: true
      Default: NULL
        Extra: 
      Visible: true
   DefineExpr:
  WhereClause:

insert into wrong
[ANALYSIS_ERROR]TStatus: errCode = 2, detailMessage = column has no source field, column=mva_SUM__CASE WHEN 1 IS NULL THEN 0 ELSE 1 END

now

desc tbl all
*************************** 26. row ***************************
    IndexName: idx
IndexKeysType: AGG_KEYS
        Field: mv_date_format(hours_add(happen_time, 1), '%Y-%m-%d %H:00:00')
         Type: varchar(65533)
 InternalType: varchar(65533)
         Null: Yes
          Key: true
      Default: NULL
        Extra: 
      Visible: true
   DefineExpr: date_format(hours_add(`happen_time`, 1), '%Y-%m-%d %H:00:00')
  WhereClause: (`k1` > '2025-06-12 00:00:00')

insert into ok

@wyxxxcat
Copy link
Contributor Author

run buildall

@hello-stephen
Copy link
Contributor

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

@wyxxxcat wyxxxcat changed the title [fix](mv) Analyze idx meta in Olap Table after restore commit [fix](restore) Analyze idx meta in Olap Table after restore commit Jun 18, 2025
@wyxxxcat wyxxxcat marked this pull request as ready for review June 19, 2025 01:43
@wyxxxcat wyxxxcat requested a review from yiguolei as a code owner June 19, 2025 01:43
Copy link
Contributor

@dataroaring dataroaring left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

PR approved by at least one committer and no changes requested.

@github-actions github-actions bot added approved Indicates a PR has been approved by one committer. reviewed labels Jun 19, 2025
Copy link
Contributor

PR approved by anyone and no changes requested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by one committer. reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants