I have a table shown below
| Id | Retweet_count | Fav_count |
|---|---|---|
| 1 | 5 | 8 |
| 2 | 3 | 3 |
| 3 | 4 | 1 |
| 4 | 0 | 1 |
How do i create a new column in the table called "Total_interaction", where it shows the values of the sum of both Retweet_count and Fav_count like this.
| Id | Retweet_count | Fav_count | Total_interaction |
|---|---|---|---|
| 1 | 5 | 8 | 13 |
| 2 | 3 | 3 | 6 |
| 3 | 4 | 1 | 5 |
| 4 | 0 | 1 | 1 |
Currently i have my connection to my database as shown below.
import sqlite3
conn = sqlite3.connect('tweets_data.sqlite')
cur = conn.cursor()