You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
tx.exec("INSERT INTO movies (name, factors) VALUES ($1, $2)", pqxx::params{item_id, factors});
89
+
tx.exec(
90
+
"INSERT INTO movies (name, factors) VALUES ($1, $2)", pqxx::params{item_id, factors}
91
+
);
88
92
}
89
93
90
94
std::string movie{"Star Wars (1977)"};
91
95
std::cout << "Item-based recommendations for " << movie << std::endl;
92
-
pqxx::result result = tx.exec("SELECT name FROM movies WHERE name != $1 ORDER BY factors <=> (SELECT factors FROM movies WHERE name = $1) LIMIT 5", pqxx::params{movie});
96
+
pqxx::result result = tx.exec(
97
+
"SELECT name FROM movies WHERE name != $1 ORDER BY factors <=> (SELECT factors FROM movies WHERE name = $1) LIMIT 5",
0 commit comments