Edit Values In A Row By Name Of Row

The title is a little vague; wasn't sure how to word it.

Anyway, what I'm wanting to do is use a button, and when pressed, it would get the name of the current window (this part isn't a problem), and then it would look in the SQLite database for the row that has the 'entity_name' column value that is the same as the title of the window, and then it would go into that row and change the 'favorite' column value to 1.

So, that's what I'd like it to do, and the part that I actually can't figure out is just checking all the rows for the one with the correct name value, and then just making the one change in that row.

Answers


Something like:

Update [table name] Set favorite= '1' Where ColumName = 'entity_name'

Need Your Help

Create SQL Server server performance benchmark query

performance sql-server-2008 database-performance

I'm looking for a simple query to say something about database performance

Finding the shortest paths of a directed graph C++

c++ graph graph-algorithm dijkstra shortest-path

Over the last week, I have implemented a Digraph by parsing an input file. The graph is guaranteed to have no cycles. I have successfully created the graph, used methods to return the number of ver...