Skip to contentSkip to conversation

Correct wrong table name 'tko_test_view' in tko/frontend.py.

PATCH In review Feng Yang 2 participants 2 messages Mar 22, 2010 – Mar 25, 2010 KVM

lore
Share & tools
lore

Feng Yang

author
#0 lore raw

PATCH 1/1 Correct wrong table name 'tko_test_view' in tko/frontend.py.

Change tko_test_view to tko_test_view_2.
autotest_web do not have tko_test_view table.

---
 tko/frontend.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
tko/frontend.py +1 -1
index 9033c20..0fd61f9 100644
@@ -85,7 +85,7 @@ def get_matrix_data(db_obj, x_axis, y_axis, where = None,
     fields = ','.join(query_fields_list)
 
     group_by = '%s, %s, status' % (x_field, y_field)
-    rows = db_obj.select(fields, 'tko_test_view',
+    rows = db_obj.select(fields, 'tko_test_view_2',
                     where=where, group_by=group_by, max_rows = MAX_RECORDS)
     return status_data(rows, x_field, y_field, query_reasons)
 
Signature · 1 line
1.5.5.6
#1 lore raw

Before we apply this patch, can we troubleshoot this a bit? Some scripts will probably break, as tko_test_view_2 has different column names.

tko_test_view should have been created in frontend migration 46, or via the full schema in database/schema_051.sql for new databases. Could it have been inadvertently dropped at some point?

-James

Quoted 24 lines · Feng Yang

Change tko_test_view to tko_test_view_2.
autotest_web do not have tko_test_view table.

---
 tko/frontend.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
tko/frontend.py +1 -2
index 9033c20..0fd61f9 100644
@@ -85,7 +85,7 @@ def get_matrix_data(db_obj, x_axis, y_axis, where = None,
    fields = ','.join(query_fields_list)
 
    group_by = '%s, %s, status' % (x_field, y_field)
-    rows = db_obj.select(fields, 'tko_test_view',
+    rows = db_obj.select(fields, 'tko_test_view_2',
                    where=where, group_by=group_by, max_rows = MAX_RECORDS)
    return status_data(rows, x_field, y_field, query_reasons)
 
--

1.5.5.6

Quoted 5 lines

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest