Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void AddURLToDB(string *result, string todaysDate, Connection *connection){
- Query query = connection->query();
- query << "SELECT url FROM " + todaysDate + " WHERE (url)='" + (*result) + "'";
- StoreQueryResult res = query.store();
- if (res){
- Row row = res[0];
- if (row.empty()){
- cout << (*result) << endl;
- }
- else {
- cout << (*result) << "already in DB" << endl;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement