| Index: chrome/browser/history/url_database.cc
|
| diff --git a/chrome/browser/history/url_database.cc b/chrome/browser/history/url_database.cc
|
| index 3f297bdbce4f68ea3f7cfb078eb7ac8a4932b0a6..dd3346b8c893d1df203c241e2576e49c99175bda 100644
|
| --- a/chrome/browser/history/url_database.cc
|
| +++ b/chrome/browser/history/url_database.cc
|
| @@ -386,6 +386,26 @@ bool URLDatabase::SetKeywordSearchTermsForURL(URLID url_id,
|
| return statement.Run();
|
| }
|
|
|
| +bool URLDatabase::GetKeywordSearchTermRow(URLID url_id,
|
| + KeywordSearchTermRow* row) {
|
| + DCHECK(url_id);
|
| + sql::Statement statement(GetDB().GetCachedStatement(SQL_FROM_HERE,
|
| + "SELECT keyword_id, term FROM keyword_search_terms WHERE url_id=?"));
|
| + if (!statement)
|
| + return false;
|
| +
|
| + statement.BindInt64(0, url_id);
|
| + if (!statement.Step())
|
| + return false;
|
| +
|
| + if (row) {
|
| + row->url_id = url_id;
|
| + row->keyword_id = statement.ColumnInt64(0);
|
| + row->term = statement.ColumnString16(1);
|
| + }
|
| + return true;
|
| +}
|
| +
|
| void URLDatabase::DeleteAllSearchTermsForKeyword(
|
| TemplateURLID keyword_id) {
|
| DCHECK(keyword_id);
|
|
|