Skip to content
forcedotcom avatar

Platform Soql Query

Salesforce SOQL and SOSL authoring and optimization skill that generates queries and analyzes query plans for performance.

CCM score
65 of 100
skills.sh installs
7.4K
GitHub stars
1.2K
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers natural-language-to-query generation, relationship queries, aggregates, semi-joins and anti-joins, and SOSL text search
  • Includes 11 reference files, 5 query asset templates, and a post-write hook that validates .soql edits with static checks and query plan analysis
  • Enforces selective filtering, field-minimal queries, no queries inside Apex loops, and a 100-point score guide from 70 to 90 and above
  • Designed for developers who write or debug SOQL, with bulk data operations and Apex DML delegated to other skills

Install

$ npx -y skills add forcedotcom/sf-skills --skill platform-soql-query -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

platform-soql-query: Salesforce SOQL Query Expert

Use this skill when the user needs SOQL/SOSL authoring or optimization: natural-language-to-query generation, relationship queries, aggregates, query-plan analysis, and performance/safety improvements for Salesforce queries.

When This Skill Owns the Task

Use platform-soql-query when the work involves:

  • .soql files
  • query generation from natural language
  • relationship queries and aggregate queries
  • query optimization and selectivity analysis
  • SOQL/SOSL syntax and governor-aware design

Delegate elsewhere when the user is:


Required Context to Gather First

Details

Repository
github.com/forcedotcom/sf-skills
Categories
Databases, Technical Documentation
First seen
Jul 14, 2026

Questions

What does the platform-soql-query skill do?

It generates, optimizes and analyzes SOQL and SOSL queries for Salesforce, turning natural-language requests into queries with relationship queries, aggregates, query-plan analysis and performance or safety improvements. It also scores queries on a 100-point scale.

How do I install the platform-soql-query skill?

Run npx -y skills add forcedotcom/sf-skills --skill platform-soql-query -y in a project. Once installed, the agent can write, optimize and debug SOQL and SOSL queries and work with .soql files.

Where does platform-soql-query rank in the Databases category?

It ranks in the top 100 on the Databases category page of Claude Marketplaces. It covers SOQL authoring, relationship queries, aggregates and query selectivity, which are specific to Salesforce data.

When should I not use platform-soql-query?

Use other skills for bulk data operations, which go to platform-data-manage, and for Apex DML logic, which goes to platform-apex-generate. Report and dashboard queries are also outside this skill's scope.

What tools does platform-soql-query need?

The skill lists the sf CLI at version 2.0.0 or later, python3 at 3.10.0 or later and jq at 1.6.0 or later. The sf CLI is used to run queries against an org and to inspect query plans.

More from forcedotcom/sf-skills

All 78

Similar to Platform Soql Query

More Databases