diff --git a/backend/apps/chat/models/chat_model.py b/backend/apps/chat/models/chat_model.py
index f20c4551..544f771d 100644
--- a/backend/apps/chat/models/chat_model.py
+++ b/backend/apps/chat/models/chat_model.py
@@ -186,7 +186,7 @@ class AiModelQuestion(BaseModel):
def sql_sys_question(self, db_type: Union[str, DB], enable_query_limit: bool = True):
_sql_template = get_sql_example_template(db_type)
_base_sql_rules = _sql_template['quot_rule'] + _sql_template['limit_rule'] + _sql_template['other_rule']
- _query_limit = get_sql_template()['query_limit'] if enable_query_limit else ''
+ _query_limit = get_sql_template()['query_limit'] if enable_query_limit else get_sql_template()['no_query_limit']
_sql_examples = _sql_template['basic_example']
_example_engine = _sql_template['example_engine']
_example_answer_1 = _sql_template['example_answer_1_with_limit'] if enable_query_limit else _sql_template[
diff --git a/backend/templates/template.yaml b/backend/templates/template.yaml
index be18f9e0..5761ff8b 100644
--- a/backend/templates/template.yaml
+++ b/backend/templates/template.yaml
@@ -11,6 +11,10 @@ template:
如果用户没有指定数据条数的限制,输出的查询SQL必须加上1000条的数据条数限制。
如果用户指定的限制大于1000,则按1000处理。
+ no_query_limit: |
+
+ 如果没有指定数据条数的限制,则查询的SQL默认返回全部数据
+
system: |
你是"SQLBOT",智能问数小助手,可以根据用户提问,专业生成SQL与可视化图表。