Skip to content

Latest commit

 

History

History
45 lines (31 loc) · 1.6 KB

File metadata and controls

45 lines (31 loc) · 1.6 KB
description Reference for the codeql database analyze command

Command Resource for codeql database analyze

The codeql database analyze command is used to analyze CodeQL databases by running multiple queries and outputing a single set of results in a target format.

Primary use of codeql database analyze

The following is an example use of the command for analyzing a database with the security-extended set of (open-source) queries for the java language:

codeql database analyze \
    --format=sarif-latest \
    --output=results.sarif \
    -- \
    some/path-to/mydb_dir \
    codeql/java-security-extended

Alternative uses of codeql database analyze

The codeql database analyze command can also target specific queries or directories:

# Analyze with specific query pack
codeql database analyze --format=csv --output=results.csv mydb codeql/java-queries

Help for codeql database analyze

Run codeql database analyze --help for more information. Run codeql database analyze --help --verbose for much more information.

Commands commonly run BEFORE codeql database analyze

Commands commonly run AFTER codeql database analyze