GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Check/Repair Database SQL command · Issue #225 · ArcadeData/arcadedb

Check/Repair Database SQL command #225

New issue
Copy link
New issue
Copy link
Closed
Closed
Check/Repair Database SQL command#225
Copy link
Assignees
lvca
Labels
enhancementNew feature or request
Milestone
21.12.1

Description

@lvca
lvca
opened on Nov 30, 2021
Issue body actions

Discussed in #222

Originally posted by jimmarino November 28, 2021
Sometimes we wind up with a dead in-vertex on an edge. This can happen due to an application error (e.g. a vertex is deleted that is an in-vertex of a uni-directional edge and the app does not also remove the edge) or in other situations. This results in a RecordNotFoundException when traversing a dead edge.

It would be helpful to have a command (or the ability) to have the database remove dead edges either by edge type or out-vertex type/edge type combination.

Activity

  1. lvca
    added
    enhancementNew feature or request
    on Nov 30, 2021
  2. lvca
    self-assigned this
    on Nov 30, 2021
  3. lvca
    added this to the 21.12.1 milestone on Nov 30, 2021
  4. lvca commented on Dec 2, 2021

    @lvca
    lvca
    on Dec 2, 2021
    MemberAuthor
    More actions

    Ok, the 1st version of this command is done, pushed in master, and it will be released with 21.12.1. I suggest running CHECK DATABASE without the FIX option first to have a report about any issues found.

    We need more tests by simulating more broken databases (not that easy).


    Executes an integrity check and in case of a repair of the database. This command analyzes the following things:

    • buckets: all the pages and records are scanned and checked if can be loaded (no physical corruption)
    • vertices: all the vertices are loaded and all the connected edges are checked. In case some edges point to records that have been
      deleted they can be fixed automatically if the FIX option is enabled.
    • edges: scan all the edges and check the incoming and outgoing links are consistent in the relative vertices. If not, the edges can
      be automatically removed if the FIX option is enabled.

    Syntax

    CHECK DATABASE [ TYPE <type-name>[,]* ] [ BUCKET <bucket-name>[,]* ] [ FIX ]
    • <type-name> Optional, if specified limit the check (and the fix) only to the specific types
    • <bucket-name> Optional, if specified limit the check (and the fix) only to the specific buckets
    • FIX Optional, if defined auto fix the issue found with the check

    The command returns the integrity check report in one record.

    Examples

    • Execute the integrity check of the entire database without fixing any issue found.
    ArcadeDB> CHECK DATABASE
    
    • Execute the integrity check of the types 'Account' and 'Bill' without fixing any issue found.
    ArcadeDB> CHECK DATABASE BUCKET "Account", "Bill"
    
    • Execute the integrity check of the entire database and auto-fix any issues found.
    ArcadeDB> CHECK DATABASE FIX
    

    Official docs are updated with this new command: https://docs.arcadedb.com/#SQL-Check-Database.

  5. lvca commented on Dec 2, 2021

    @lvca
    lvca
    on Dec 2, 2021
    MemberAuthor
    More actions

    Added more test case with broken page and removed vertex

  6. lvca
    closed this as completedon Dec 2, 2021
  7. lvca commented on Dec 2, 2021

    @lvca
    lvca
    on Dec 2, 2021
    MemberAuthor
    More actions

    Commits:

    • d9d4036
    • 4c8d315
  8. mergify
    added a commit that references this issue on Dec 1, 2025

    chore(deps): bump org.apache.maven.plugins:maven-assembly-plugin from…

    aadbdfa
  9. mergify
    added a commit that references this issue on May 24, 2026

    chore(studio-deps-dev)(deps-dev): bump the build-tools group in /stud…

    177ff50
  10. tae898
    added 2 commits that reference this issue on Jun 28, 2026

    chore(deps): bump org.apache.maven.plugins:maven-assembly-plugin from…

    d6fbaf2

    chore(studio-deps-dev)(deps-dev): bump the build-tools group in /stud…

    55b10f7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @lvca
    lvca

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    • 21.12.1

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.