Semmle 1.19
Skip to end of metadata
Go to start of metadata

On this page:

Related topics:

HIDDEN

 

Visit the Learning QL home page to view all of the resources available for learning how to write QL.

You can get started using the query console on LGTM. On LGTM.com, you can write QL code to query open source projects directly—without having to download snapshots and libraries. If your organization uses LGTM Enterprise, you can use this to query private projects too. The query console provides autocomplete suggestions, the option to "jump to definition", and many more writing aids. Alternatively, you can install a QL plugin to write and run queries locally. For more information, see QL plugins and extensions. Once you have installed a plugin and obtained a snapshot to run queries against, you can start writing QL in your IDE.

Getting started

If you are new to QL, start with the following topics:

  1. QL detective tutorials—A general introduction to QL, with steps to learn how to write your own queries and understand the basic QL syntax.
  2. Language-specific resources—A list of tutorials to teach you how to query code written in a specific language:
  3. QL built-in queries—An overview of the queries in the most recent release of the QL tools.
  4. QL cookbooks—A collection of short example queries that show you how to use QL in practice. You can use these cookbook queries as a starting point for your own experiments.

Writing custom queries

For more examples and information about writing queries to run as part of custom analysis for your project, see Writing QL queries.

The Semmle QL open source repository

The Semmle QL open source repository contains the standard QL libraries and queries that power LGTM and the other products that Semmle makes available to its customers worldwide. Contributions and improvements are welcome—visit the repository to learn more.

Reference topics

For more comprehensive information about QL, see the following reference topics:

  • QL standard libraries—Full details of the standard QL libraries. These contain predicates, modules, and classes that help you analyze code written in the languages supported by Semmle.
  • QLDoc specification—A reference of the terminology and syntax for QLDoc comments.