SQL query fixes
Errors in syntax, types, JOIN, GROUP BY, CTE and window functions, duplicate rows, incorrect totals and empty results.
Help with SQL queries, errors, reports, data exports, PostgreSQL, Greenplum, Oracle PL/SQL and migration of SQL logic between database management systems.
SELECT department,
COUNT(*) AS total
FROM requests
WHERE created_at >=
CURRENT_DATE - INTERVAL '30 days'
GROUP BY department;Send the query, error message, DBMS version and an anonymized example. Passwords, access keys and real personal data are not needed.
How to submit a task ↗Errors in syntax, types, JOIN, GROUP BY, CTE and window functions, duplicate rows, incorrect totals and empty results.
Analysis of slow queries, rewriting JOIN operations and subqueries, and recommendations on indexes and execution plans.
PL/pgSQL, functions, temporary tables, analytical queries, Greenplum specifics, type errors and result structure errors.
Migration of SQL logic, functions and procedures: DECODE, NVL, dates, MERGE, cursors, packages, PL/pgSQL.
SQL queries for Excel, BI, CRM, ERP, sales, inventory, customers, payments, documents and data reconciliation.
Reviewing SQL written by others, finding errors, simplifying logic, adding comments, documenting and rewriting queries.
You can send the query text, error, table definitions and expected result. Database access is not always required.
Migrating SQL logic requires adapting functions, types, dates, procedural logic and DBMS behavior rather than mechanically replacing words.
Preparing queries to export data on sales, customers, inventory, payments, documents, products, groups, periods and statuses.
| Initial task review | from 3 000 ₽ |
| Fixing a simple SQL query | from 5 000 ₽ |
| Developing an SQL data export | from RUB 10,000 |
| Optimizing a slow query | from RUB 15,000 |
| PL/pgSQL function | from RUB 20,000 |
| Oracle PL/SQL → PostgreSQL migration | from RUB 25,000 |
| SQL code audit | from RUB 20,000 |
| Urgent task | quoted individually |
The final cost depends on the DBMS, amount of code, availability of table schemas, urgency, testing requirements and complexity of the business logic.
The query, error, DBMS, table structures, expected result and constraints.
What data is needed, how the result is calculated, and where an error or slowdown occurs.
Corrected SQL, explanations, recommendations and, where needed, optimization options.
Yes. For an initial review, the query text, error, table structures and expected result are often sufficient. For optimization, an execution plan and an indication of data volumes are desirable.
Yes. Differences in functions, data types, dates, procedural logic and syntax must be taken into account. Sometimes a change of approach is needed rather than a direct replacement.
Yes, with the query text, table structures, an indication of data volumes and preferably EXPLAIN / EXPLAIN ANALYZE. Recommendations on indexes and rewriting the logic can also be provided.
Yes. An SQL query can be prepared for the required fields, filters, groupings, periods and result format.
Before changing SQL, it is useful to record what constitutes a correct result: the set of columns, selection rules, level of detail, permissible duplicates and how totals are calculated. A test example includes a small schema, anonymized records and the expected result. This set helps distinguish a syntax error from a misunderstanding of the report.
Optimization checks have two parts. First, the results of the original and modified queries are compared: row counts, keys, control totals for metrics and disputed examples. Measurements are then compared on an agreed volume of data. A fast response that loses rows is not considered a useful optimization result.
In PostgreSQL, EXPLAIN ANALYZE actually executes the query being examined. Its use with operations that modify data and with resource-intensive queries is therefore agreed in advance; a prepared test copy is preferable. A plan without actual execution data is useful for an initial review, but does not replace checking the resulting output in a working scenario.
The migration of a report or procedure is assessed by its behavior on agreed data. In addition to successful execution, checks cover the rules for missing values, type conversion, rounding, dates and time boundaries. Even a small change to a join condition or filter can alter the final totals in a query that looks similar.
If a procedure modifies data, the sequence of operations, error handling and state of the tables after an incomplete run are examined separately. For reporting queries, the same granularity is checked: results per document, document line or group of objects. These levels must not be changed without making it clear when rewriting a query.
After migration, it is useful to retain the SQL script, a list of changes and reference results. Unresolved dependencies are explicitly noted: for example, a called function has not been provided or the rule for populating a field is unknown. This list allows work to resume from a specific question and further verification to be agreed without sharing unnecessary production data or access credentials.
Include the query text, error, table structures, DBMS and expected result. You can start without database access, using code and a description.
Contact us by email
Describe your SQL task in an email. If needed, attach an anonymized query, error description and table structures.
Write an emailThe button will open your email application. You can also copy the address and write from your email service.
Do not send passwords, tokens or access credentials for production systems.
Only the data necessary to consider the inquiry is used. If processing is based on consent, send it in a separate email following the instructions · Terms for submitting materials · Cookies and technical data · All legal documents. An email containing a question does not itself constitute universal consent.
Personal Data Processing Policy · Consent to Personal Data Processing · Terms for submitting materials · Cookies and technical data · All legal documents