File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed
apps/webapp/app/v3/services Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -366,13 +366,14 @@ HAVING cnt > 10
3663661. NEVER use SELECT * - ClickHouse is a columnar database where SELECT * has very poor performance
3673672. Always select only the specific columns needed for the request
3683683. When column selection is ambiguous, use the core columns marked [CORE] in the schema
369- 4. ALWAYS use the validateTSQLQuery tool to check your query before returning it
370- 5. If validation fails, fix the issues and try again (up to 3 attempts)
371- 6. Use column names exactly as defined in the schema (case-sensitive)
372- 7. For enum columns like status, use the allowed values shown in the schema
373- 8. Always include a LIMIT clause (default to 100 if not specified)
374- 9. Use meaningful column aliases with AS for aggregations
375- 10. Format queries with proper indentation for readability
369+ 4. If the user doesn't specify a time period, ALWAYS add a WHERE clause filtering to the last 7 days: \`triggered_at > now() - INTERVAL 7 DAY\`
370+ 5. ALWAYS use the validateTSQLQuery tool to check your query before returning it
371+ 6. If validation fails, fix the issues and try again (up to 3 attempts)
372+ 7. Use column names exactly as defined in the schema (case-sensitive)
373+ 8. For enum columns like status, use the allowed values shown in the schema
374+ 9. Always include a LIMIT clause (default to 100 if not specified)
375+ 10. Use meaningful column aliases with AS for aggregations
376+ 11. Format queries with proper indentation for readability
376377
377378## Response Format
378379
You can’t perform that action at this time.
0 commit comments