|
@@ -24,7 +24,7 @@
|
|
|
#%option
|
|
|
#% key: type
|
|
|
#% type: string
|
|
|
-#% description: Type of the space time dataset, default is strds
|
|
|
+#% description: Type of the space time dataset or map, default is strds
|
|
|
#% required: no
|
|
|
#% options: strds, str3ds, stvds, rast, rast3d, vect
|
|
|
#% answer: strds
|
|
@@ -36,17 +36,17 @@
|
|
|
#% description: Sort the space time dataset by category. Columns number_of_maps and granularity only available fpr space time datasets
|
|
|
#% required: no
|
|
|
#% multiple: yes
|
|
|
-#% options: id, name, creator, mapset, number_of_maps, creation_time, modification_time, start_time, end_time, interval, north, south, west, east, granularity
|
|
|
+#% options: id, name, creator, mapset, number_of_maps, creation_time, start_time, end_time, interval, north, south, west, east, granularity
|
|
|
#% answer: id
|
|
|
#%end
|
|
|
|
|
|
#%option
|
|
|
#% key: columns
|
|
|
#% type: string
|
|
|
-#% description: Which columns should be printed to stdout. Columns number_of_maps and granularity only available fpr space time datasets
|
|
|
+#% description: Which columns should be printed to stdout. Columns number_of_maps and granularity only available for space time datasets
|
|
|
#% required: no
|
|
|
#% multiple: yes
|
|
|
-#% options: id, name, creator, mapset, number_of_maps, creation_time, modification_time, revision, start_time, end_time, north, south, west, east, granularity, all
|
|
|
+#% options: id, name, creator, mapset, number_of_maps, creation_time, start_time, end_time, north, south, west, east, granularity, all
|
|
|
#% answer: id
|
|
|
#%end
|
|
|
|
|
@@ -116,11 +116,12 @@ def main():
|
|
|
else:
|
|
|
sql = "SELECT * FROM " + table
|
|
|
|
|
|
+ if where:
|
|
|
+ sql += " WHERE " + where
|
|
|
+
|
|
|
if order:
|
|
|
sql += " ORDER BY " + order
|
|
|
|
|
|
- if where:
|
|
|
- sql += " WHERE " + where
|
|
|
|
|
|
dbif.cursor.execute(sql)
|
|
|
rows = dbif.cursor.fetchall()
|