First time here? Check out the Help page!
1 | initial version |
The problem is the structure of the underlying SQL, it doesn't really has a subcategory column so it end up being positional...
Try this query:
SELECT ColumnName as "Utility", Rowname as "End Use", Value, Units
FROM TabularDataWithStrings
WHERE ReportName = "AnnualBuildingUtilityPerformanceSummary"
AND ReportForString='Entire Facility'
AND TableName = "End Uses By Subcategory"
// Optional: AND ColumnName != "Subcategory"
If you just pivot the Utility column it should look like the HTML report I think. There is no pivot in SQLite, so I'd just do it somewhere else (python is my goto for that), but you could write a verbose JOIN query to do that in SQLite
2 | No.2 Revision |
The problem is the structure of the underlying SQL, it doesn't really has a subcategory column so it end ends up being positional...
Try this query:
SELECT ColumnName as "Utility", Rowname as "End Use", Value, Units
FROM TabularDataWithStrings
WHERE ReportName = "AnnualBuildingUtilityPerformanceSummary"
AND ReportForString='Entire Facility'
AND TableName = "End Uses By Subcategory"
// Optional: AND ColumnName != "Subcategory"
If you just pivot the Utility column it should look like the HTML report I think. There is no pivot in SQLite, so I'd just do it somewhere else (python is my goto for that), but you could write a verbose JOIN query to do that in SQLite