PromptBase
Upgrade
Close icon
General
Home
Marketplace
Create
Hire
Login
Chat
Sell
Explore

Prompt Details

Model
Chat - (gpt-5.5)
Token size
249
Example input
[DESCRIBE WHAT DATA YOU NEED IN PLAIN ENGLISH]: All accounts with open opportunities over $50K in the last 90 days
Example output
Input: "All accounts with open opportunities over $50K in the last 90 days" SOQL: SELECT Id, Name, (SELECT Id, Name, Amount, CloseDate, StageName FROM Opportunities WHERE Amount > 50000 AND IsClosed = false AND CloseDate = LAST_90_DAYS) FROM Account WHERE Id IN (SELECT AccountId FROM Opportunity WHERE Amount > 50000 AND IsClosed = false AND CloseDate = LAST_90_DAYS) ## Optimization Notes - Main WHERE uses a semi-join — fine for up to ~50K accounts - Governor limit risk: Low - Consider custom index on Opportunity: Amount + IsClosed + CloseDate ## Apex Version public static List<Account> getAccountsWithHighValueOpps() { return [SELECT Id, Name, (SELECT Id, Name, Amount, CloseDate, StageName FROM Opportunities WHERE Amount > 50000 AND IsClosed = false AND CloseDate = LAST_90_DAYS) FROM Account WHERE Id IN (SELECT AccountId FROM Opportunity WHERE Amount > 50000 AND IsClosed = false AND CloseDate = LAST_90_DAYS)]; }
🤖 GPT

Soql Query Optimizer Generator

Add to Cart
Instant accessInstant access
Usage rightsCommercial use
Money-back guaranteeMoney‑back
By purchasing this prompt, you agree to our terms of service
GPT-5.5
Tested icon
Guide icon
4 examples icon
Free credits icon
Write complex Salesforce SOQL queries from plain English descriptions. Includes automatic optimization for governor limits, relationship query syntax, and best-practice filters. Built by a Salesforce Senior Developer — handles edge cases that generic SQL generators miss.
...more
Added 1 week ago
Report
Browse Marketplace