Crea cualquier fórmula de Excel o Google Sheets a partir de una descripción en lenguaje sencillo

Por qué importa este prompt
The average professional spends over 4 hours a week on spreadsheet tasks. Complex formulas — nested IFs, array formulas, XLOOKUP — stop most people cold. Without help, you spend an hour on Stack Overflow hunting for something close enough to adapt, or you settle for a pivot table that gives you 80% of the answer. This prompt gives you the formula and the understanding to verify it and adapt it when your data changes.
Para qué lo usamos
You're building a quarterly report and need formulas to calculate tiered commissions, flag overdue invoices, and cross-reference sales data from three different sheets — but you know what you want, not which combination of VLOOKUP, IF, and SUMPRODUCT will get you there.
Prompt
Act as a senior spreadsheet consultant with 15 years of experience in Excel and Google Sheets, who specializes in translating business requirements into formulas that non-technical users can understand and maintain. I need to build a formula for the following task: [DESCRIBE YOUR CALCULATION IN PLAIN ENGLISH — e.g., "I want to find the total sales for each region, but only count sales where the status is 'Closed Won' and the deal size is above $10,000"] My spreadsheet has these columns: [LIST YOUR COLUMN NAMES AND WHAT THEY CONTAIN — e.g., "Column A: Sales Rep Name, Column B: Region, Column C: Deal Status, Column D: Deal Size, Column E: Close Date"] I am using: [Excel / Google Sheets] INSTRUCTIONS: 1. Write the exact formula I should enter 2. Break down every function and argument in plain English — explain what each piece does and why 3. List any assumptions you made about my data 4. Flag common mistakes or edge cases (empty cells, wrong data types, case sensitivity) 5. Provide an alternative approach if a simpler formula exists 6. If Google Sheets and Excel syntax differ for this formula, show both versions Output format: FORMULA: [the exact formula to copy and paste] HOW IT WORKS: [step-by-step explanation of each function] ASSUMPTIONS: [what I assumed about your data] WATCH OUT FOR: [common errors and edge cases] SIMPLER ALTERNATIVE (if available): [a less complex approach if one exists]
Resultado
User's input: "I need to calculate the commission for each sales rep. Commission is 5% of total sales if they sold under $50,000 this month, 7% if between $50,000–$100,000, and 10% if over $100,000. Column A has rep names, Column B has their total monthly sales."
FORMULA:
=IF(B2<50000, B2*0.05, IF(B2<=100000, B2*0.07, B2*0.1))
HOW IT WORKS:
This formula uses nested IF statements to apply tiered commission rates. Starting from the outside in:
IF(B2<50000, ...)— Checks whether the sales total in B2 is less than $50,000. If TRUE: calculates B2*0.05 (5% commission) and stops. If FALSE: moves to the inner IF.IF(B2<=100000, ...)— Since we already know B2 is at least $50,000, this checks if it's $100,000 or under. If TRUE: calculates B2*0.07 (7% commission). If FALSE: must be above $100,000.B2*0.1— The final 10% tier applies to any value above $100,000.
To apply to the full column, drag this formula down from row 2 to match your data range.
ASSUMPTIONS:
- Column B contains numeric values (not formatted as text — left-aligned numbers indicate text format)
- Row 2 is your first data row (Row 1 is your header)
- Sales totals are already summed monthly totals, not individual transactions
WATCH OUT FOR:
- Empty cells: If B2 is blank, the formula returns 0. Add
IF(B2="","",IF(...))to return blank instead of zero if preferred. - Negative values: If a rep had returns that brought their total negative, the first tier fires and produces a negative commission. Add
MAX(0, [formula])to floor it at zero. - Boundary confusion: $50,000 and $100,000 fall into the middle and top tiers respectively — the formula uses <= not < at the second check to include $100,000 in the 7% tier.
SIMPLER ALTERNATIVE:
If you add a lookup table with thresholds in one column and rates in another, you can replace the nested IF with VLOOKUP using approximate match:
=B2*VLOOKUP(B2, {0,0.05;50000,0.07;100000,0.1}, 2, TRUE)
This is easier to update when rates change — just edit the numbers in one place rather than rewriting nested logic. Works in both Excel and Google Sheets. When commission tiers change next quarter, your manager can update the table without touching the formula.
Las fórmulas complejas de hojas de cálculo son un precipicio de productividad. Sabes exactamente qué análisis necesitas — cruzar datos de ventas de tres hojas, marcar facturas con más de 30 días, calcular bonificaciones escalonadas — pero en cuanto aparece VLOOKUP, SUMPRODUCT o un IF anidado, la mayoría de los profesionales o llaman a un colega o se conforman con algo más simple.
Este prompt elimina esa fricción. Actúa como un consultor senior de hojas de cálculo que no solo escribe la fórmula correcta, sino que explica cada argumento en lenguaje sencillo, señala los casos límite antes de que causen resultados erróneos y ofrece una alternativa más simple cuando existe.
Qué hace diferente a este prompt
La mayoría de las solicitudes a IA para ayuda con hojas de cálculo producen una fórmula sin explicación — no puedes verificar que sea correcta, y cuando tu estructura de datos cambia, no puedes adaptarla. Este prompt está diseñado alrededor de cinco secciones de salida estructuradas que construyen tu comprensión, no solo te dan una respuesta:
- FORMULA — La fórmula exacta para copiar y pegar
- HOW IT WORKS — Cada función y argumento explicado en lenguaje sencillo
- ASSUMPTIONS — Lo que la IA asumió sobre la estructura de tus datos
- WATCH OUT FOR — Celdas vacías, números con formato de texto, condiciones límite
- SIMPLER ALTERNATIVE — Un enfoque menos complejo cuando existe
Esa última sección suele ser la más valiosa. Una fórmula SUMPRODUCT que funciona es impresionante; una tabla de búsqueda con coincidencia aproximada VLOOKUP que tu gerente pueda actualizar por sí mismo es mejor ingeniería. El prompt solicita explícitamente ambas opciones.
Para quién es esto
Este prompt ofrece el mayor valor para analistas, gerentes de operaciones, equipos financieros y gerentes de proyectos que usan hojas de cálculo como su herramienta de datos principal pero no son usuarios avanzados de fórmulas. Si puedes describir claramente qué cálculo necesitas pero no sabes qué funciones de Excel combinar — este prompt es para ti.
Cómo usarlo
Completa dos secciones entre corchetes antes de enviar:
- Describe tu cálculo en lenguaje sencillo. Sé específico — «contar ventas donde el estado es Closed Won y el tamaño del trato supera los diez mil dólares» es mucho mejor que «contar ventas». Cuanto más precisa sea tu descripción, más precisa será la fórmula. Incluye condiciones, umbrales o excepciones.
- Enumera los nombres de tus columnas y lo que contienen. Nombra las columnas relevantes: Columna A Nombre del representante de ventas, Columna B Región, Columna C Tamaño del trato.
Especifica Excel o Google Sheets. Cuando su sintaxis difiere — XLOOKUP no existe en Sheets — el prompt proporciona automáticamente ambas versiones.
Ejemplo real de salida
Para un problema de comisiones de ventas escalonadas — cinco por ciento por debajo de cincuenta mil dólares, siete por ciento entre cincuenta y cien mil, diez por ciento por encima de cien mil — el prompt produce la fórmula IF anidada, un recorrido en lenguaje sencillo de cada verificación de nivel, una advertencia de que las celdas vacías devuelven cero en lugar de blanco, una nota de que los totales de ventas negativos producirán comisiones negativas, y una alternativa de matriz VLOOKUP que es más fácil de mantener cuando las tasas de comisión cambien el próximo trimestre.
Modelos compatibles
Optimizado para Claude Sonnet 4.6 y GPT-4o, que ambos producen salida estructurada de múltiples secciones confiable. También funciona con Gemini 2.5 Pro. Para fórmulas que abarcan varias hojas o implican referencias cruzadas complejas, Claude tiende a producir explicaciones más limpias de la lógica anidada.