Commit 398b0e6d authored by Jan Köster's avatar Jan Köster
Browse files

test

parent a514a367
Loading
Loading
Loading
Loading
+2 −2
Changes for src/conf.h: 2 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -194,9 +194,9 @@ namespace blogi {
        if(rows<1){
            uuid::uuid id;
            id.generate();
            sql << "INSERT INTO OPTIONS (id," << keyColumn << ",value) VALUES ('"<< id.c_str() <<"','"<< dbpp::SQL::escaped(buf,key.c_str()) << "','" << dbpp::SQL::escaped(buf,value.c_str()) <<"')";
            sql << "INSERT INTO options (id," << keyColumn << ",value) VALUES ('"<< id.c_str() <<"','"<< dbpp::SQL::escaped(buf,key.c_str()) << "','" << dbpp::SQL::escaped(buf,value.c_str()) <<"')";
        }else{
            sql << "UPDATE OPTIONS set value='"<<dbpp::SQL::escaped(buf,value.c_str()) <<"' WHERE " << keyColumn << "='"<< dbpp::SQL::escaped(buf,key.c_str())  <<"'";
            sql << "UPDATE options set value='"<<dbpp::SQL::escaped(buf,value.c_str()) <<"' WHERE " << keyColumn << "='"<< dbpp::SQL::escaped(buf,key.c_str())  <<"'";
        }
        db.exec(sql,res);
    }