Still in the process of switching to prepared statements. Left TODO for removing the make_shared_ptr for the raw song data. Added feature to retrieve a sing cover art record in json format

This commit is contained in:
kdeng00
2019-09-05 20:57:13 -04:00
parent 5b9f2a0505
commit ada50b3d5c
8 changed files with 303 additions and 34 deletions
+2 -1
View File
@@ -34,7 +34,7 @@ model::Album database::AlbumRepository::retrieveRecord(model::Album& album, type
auto titleLength = album.title.size();
switch (filter) {
case type::AlbumFilter::id:
qry << "alb.AlbumId = " << album.id;
qry << "alb.AlbumId = ?";
params[0].buffer_type = MYSQL_TYPE_LONG;
params[0].buffer = (char*)&album.id;
@@ -64,6 +64,7 @@ model::Album database::AlbumRepository::retrieveRecord(model::Album& album, type
mysql_stmt_close(stmt);
mysql_close(conn);
std::cout << "done" << std::endl;
return album;