Fix ordering in bi-1
@@ -8,10 +8,10 @@ PREFIX foaf: <http://xmlns.com/foaf/0.1/>
PREFIX dbpedia: <http://dbpedia.org/resource/>
PREFIX dbpedia-owl: <http://dbpedia.org/ontology/>
-SELECT ?messageYear ?isComment ?lengthCat ?messageCount ?averageMessageLength ?sumMessageLength ?totalMessageCount ?percentageOfMessages
+SELECT ?messageYear ?isComment ?lengthCategory ?messageCount ?averageMessageLength ?sumMessageLength ?totalMessageCount ?percentageOfMessages
WHERE {
{
- SELECT ?messageYear ?isComment ?lengthCat (COUNT(?message) AS ?messageCount) (AVG(?length) as ?averageMessageLength) (SUM(?length) as ?sumMessageLength)
+ SELECT ?messageYear ?isComment ?lengthCategory (COUNT(?message) AS ?messageCount) (AVG(?length) as ?averageMessageLength) (SUM(?length) as ?sumMessageLength)
WHERE {
{
@@ -28,10 +28,10 @@ WHERE {
BIND( year(?creationDate) as ?messageYear) .
- BIND( IF (?length < 40, 0, IF (?length < 80 , 1, IF(?length < 160, 2, 3))) as ?lengthCat)
+ BIND( IF (?length < 40, 0, IF (?length < 80 , 1, IF(?length < 160, 2, 3))) as ?lengthCategory)
}
- GROUP BY ?messageYear ?isComment ?lengthCat
+ GROUP BY ?messageYear ?isComment ?lengthCategory
}
{
@@ -46,3 +46,4 @@ WHERE {
BIND ( ?messageCount / ?totalMessageCount as ?percentageOfMessages)
}
+ORDER BY DESC(?messageYear) ?isComment ?lengthCategory
