r/SQLServer • u/DurianVivid93 • Jun 01 '26
Question Feature Request: Add encoding options (UTF-8) for SSMS execution plan export to improve AI/LLM compatibility
**Problem:**
SSMS exports execution plans as UTF-16 LE with BOM. This is the XML standard, but modern LLM tools (Claude, ChatGPT, Copilot) and static analysis tools overwhelmingly expect UTF-8. When you paste a .sqlplan file for AI analysis, you find:
- File is 2x larger than necessary (UTF-16 doubles every ASCII char)
- AI tools show `NodeId=` null-byte separators, making the plan unreadable
- Users must manually convert encoding before sharing — friction every single time for DBA workflows
**Request:**
Add a dropdown or checkbox in the "Save Execution Plan As..." dialog:
- [ ] Save as UTF-8 or UTF-8 BOM
- [ ] Save as UTF-16 LE (default, current behavior)
Or a global option in Tools → Options → Query Results → SQL Server → Execution Plan:
- Default export encoding: [UTF-16 LE | UTF-8]
**Why now:**
AI-assisted query tuning is now mainstream. DBAs paste execution plans into LLMs daily. Every major AI platform prefers UTF-8.
Azure Data Studio already defaults to UTF-8 for most outputs. SSMS should align.
**Workaround (current):**
Open .sqlplan in VS Code → "Save with Encoding" → UTF-8. Then share.
**Impact:** Low-risk change (one additional XML serialization option), high-ROI (every DBA using AI tools hits this).
**SQL Server version:** SSMS 20.x / SQL Server 2017+
•
u/AutoModerator Jun 01 '26
After your question has been solved /u/DurianVivid93, please reply to the helpful user's comment with the phrase "Solution verified".
This will not only award a point to the contributor for their assistance but also update the post's flair to "Solved".
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
9
u/VladDBA Microsoft MVP Jun 01 '26
You think posting about this on reddit would get more traction than opening a feedback item on https://developercommunity.visualstudio.com/SSMS ?
Also,
Doubt, especially with the new pricing models.
Fun fact: PSBlitz already uses UTF-8 when saving the execution plans and deadlock graphs.
2
u/Codeman119 Jun 01 '26
I have never posted a execution plan in an LLM. Those file are big and that is a lot of usage for a request.
Plus I like to look at the plan to understand what the optimization engine is looking at.
1
u/itsnotaboutthecell Microsoft Employee Jun 01 '26
!ssms
1
u/CHILLAS317 Jun 01 '26
"Every DBA using AI tools hits this"
😂