summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2020-02-26 12:48:00 +0200
committerPanu Matilainen <pmatilai@redhat.com>2020-02-27 12:51:01 +0200
commit1913d84c1e5d184ba1bb688ddda95359e60dbc1b (patch)
tree56ce5d08efa7e44dd11cd8442df319c69a3f0360
parent243041f5fb68b68102243d713a1c5a3dc52698a2 (diff)
downloadrpm-1913d84c1e5d184ba1bb688ddda95359e60dbc1b.tar.gz
Use uppercase for SQL(ite) keywords consistently, cosmetics only
-rw-r--r--lib/backend/sqlite.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/backend/sqlite.c b/lib/backend/sqlite.c
index 567213de9..d8e082344 100644
--- a/lib/backend/sqlite.c
+++ b/lib/backend/sqlite.c
@@ -476,7 +476,7 @@ static rpmRC sqlite_stepPkg(dbiCursor dbc, unsigned char **hdrBlob, unsigned int
static rpmRC sqlite_pkgdbByKey(dbiIndex dbi, dbiCursor dbc, unsigned int hdrNum, unsigned char **hdrBlob, unsigned int *hdrLen)
{
- int rc = dbiCursorPrep(dbc, "SELECT hnum, blob from '%q' where hnum=?",
+ int rc = dbiCursorPrep(dbc, "SELECT hnum, blob FROM '%q' WHERE hnum=?",
dbi->dbi_file);
if (!rc)
@@ -493,7 +493,7 @@ static rpmRC sqlite_pkgdbIter(dbiIndex dbi, dbiCursor dbc,
{
int rc = RPMRC_OK;
if (dbc->stmt == NULL) {
- rc = dbiCursorPrep(dbc, "SELECT hnum, blob from '%q'", dbi->dbi_file);
+ rc = dbiCursorPrep(dbc, "SELECT hnum, blob FROM '%q'", dbi->dbi_file);
}
if (!rc)
@@ -528,7 +528,7 @@ static unsigned int sqlite_pkgdbKey(dbiIndex dbi, dbiCursor dbc)
static rpmRC sqlite_idxdbByKey(dbiIndex dbi, dbiCursor dbc, const char *keyp, size_t keylen, dbiIndexSet *set)
{
- int rc = dbiCursorPrep(dbc, "SELECT hnum, idx from '%q' where key=?",
+ int rc = dbiCursorPrep(dbc, "SELECT hnum, idx FROM '%q' WHERE key=?",
dbi->dbi_file);
if (!rc)
@@ -560,13 +560,13 @@ static rpmRC sqlite_idxdbIter(dbiIndex dbi, dbiCursor dbc, const char *keyp, siz
if (dbc->stmt == NULL) {
if (searchType == DBC_PREFIX_SEARCH) {
- rc = dbiCursorPrep(dbc, "SELECT DISTINCT key from '%q' "
+ rc = dbiCursorPrep(dbc, "SELECT DISTINCT key FROM '%q' "
"WHERE key LIKE '%q%%' "
"AND LENGTH(key) >= %d "
"ORDER BY key",
dbi->dbi_file, keyp, keylen);
} else {
- rc = dbiCursorPrep(dbc, "SELECT DISTINCT key from '%q' "
+ rc = dbiCursorPrep(dbc, "SELECT DISTINCT key FROM '%q' "
"ORDER BY key",
dbi->dbi_file);
}