v.db.droprow(1grass)
π v.db.droprow β the GRASS User's Manual page, bestie edition π
okay so this is the manual page for v.db.droprow, and it lives in the GRASS User's Manual. she's a little vector/database icon and she's about to remove some features for you based on attribute vibes only. let's get into it π«Ά
β¨ NAME β¨
v.db.droprow β removes a vector feature from a vector map through attribute selection. that's it, that's her job, and she does it flawlessly π
πΈ KEYWORDS πΈ
vector, attribute table, database
π¦ SYNOPSIS π¦
v.db.droprow
v.db.droprow --help
v.db.droprow input=name [layer=string] where=sql_query output=name
[--overwrite] [--help] [--verbose] [--quiet] [--ui]
π Flags π
--overwriteβ lets your output files just do that and overwrite existing files. no cap, she will replace them.--helpβ prints the usage summary. your little cheat sheet bestie.--verboseβ verbose module output. she talks a LOT and we love that for her.--quietβ quiet module output. the opposite energy. silent, mysterious, iconic.--uiβ forces the GUI dialog to launch. graphical era β¨
π Parameters π
input=name[required]β name of input vector map. or, plot twist, a data source for direct OGR access. you gotta give her this, fr fr.layer=stringβ layer number or name. so here's the thing: vector features can have category values in different layers, and this number determines which layer to use. when you're using direct OGR access, this is the layer name instead. default is1.where=sql_query[required]β WHERE conditions of your SQL statement, but WITHOUT thewherekeyword. like, don't bring the keyword, she already knows. example:income < 1000 and population >= 10000output=name[required]β name for output vector map. you're making a whole new map, babes.
π DESCRIPTION π
so what does v.db.droprow actually do, you ask? she removes vector object(s) β and yes that's points, lines, areas, faces, etc., the whole squad β from a vector map, and she does it through attribute selection in the table that's connected to the given vector map. and the way she automatically checks the connection for the specified layer?? obsessed. lowkey babysitting you and you should say thank you π
π NOTES π
v.db.droprow is a front-end to v.extract (reverse selection), which exists purely to make your life easier. she's the friendly face on top of the machinery, iykyk.
and if you wanna verify your existing database connection(s), you can check them with v.db.connect. go peek, bestie, make sure everything's connected before you start dropping rows π₯
β EXAMPLES β
dropping all vector points without an elevation attribute (this is the North Carolina data set, iconic):
g.region raster=elevation -p
v.random output=rand5k_elev n=5000
v.db.addtable map=rand5k_elev column="elevation double precision"
v.what.rast vect=rand5k_elev rast=elevation column=elevation
# verify absence of some elevation attributes ("number of NULL attributes"):
v.univar rand5k_elev type=point column=elevation
# Remove all vector points lacking elevation attribute
v.db.droprow rand5k_elev output=rand5k_elev_filt where="elevation IS NULL"
# verify:
v.univar rand5k_elev_filt type=point column=elevation
look at that workflow. setup, check, drop, verify. main character energy from start to finish π
π§ SEE ALSO π§
db.droptable, db.execute, v.db.addcolumn, v.db.addtable, v.db.connect, v.db.dropcolumn, v.db.droptable, v.db.select, v.db.update
GRASS SQL interface
π AUTHOR π
Markus Neteler
π SOURCE CODE π
Available at: v.db.droprow source code (history)
Latest change: Friday Feb 07 19:16:09 2025 in commit: a82a39f673b97fafcfce1604dc3e6015cb96487a
Main index | Vector index | Topics index | Keywords index | Graphical index | Full index
Β© 2003-2026 GRASS Development Team, GRASS 8.5.0 Reference Manual
and that's the whole page, bestie π tysm for reading, this was v.db.droprow(1grass) from the GRASS User's Manual β the version in question is GRASS 8.5.0, and the latest change was Friday Feb 07 19:16:09 2025. now go drop some rows and slay β¨π¦π
π¦ where this page comes from
- alpine 3.24: grass-gis-doc 8.5.0-r1 Β· GPL-2.0-or-later
- ubuntu stonking: grass-doc 8.5.0-1ubuntu1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms