Spaces:
Running
Running
handle strings
Browse files
app.py
CHANGED
@@ -68,9 +68,10 @@ def query_sql(user_query: str) -> str:
|
|
68 |
if not generated_sql.strip().lower().startswith(("select", "show", "pragma")):
|
69 |
return "Error: Only SELECT queries are allowed."
|
70 |
|
71 |
-
result =
|
72 |
|
73 |
-
print(f"SQL Query Result: {result}")
|
|
|
74 |
|
75 |
try:
|
76 |
float_result = float(result)
|
|
|
68 |
if not generated_sql.strip().lower().startswith(("select", "show", "pragma")):
|
69 |
return "Error: Only SELECT queries are allowed."
|
70 |
|
71 |
+
result = sql_engine(generated_sql)
|
72 |
|
73 |
+
#print(f"SQL Query Result: {result}")
|
74 |
+
print({result}")
|
75 |
|
76 |
try:
|
77 |
float_result = float(result)
|