reconnect = true;
}
+ ClearIDCache();
+
String ihost, iuser, ipasswd, idb;
const char *host, *user , *passwd, *db;
long port;
if (type == DbQueryInsert && query.ConfigUpdate)
SetInsertID(query.Object, GetLastInsertID());
}
+
if (type == DbQueryInsert && query.Table == "notifications") { // FIXME remove hardcoded table name
m_LastNotificationID = GetLastInsertID();
Log(LogDebug, "db_ido", "saving contactnotification notification_id=" + Convert::ToString(static_cast<long>(m_LastNotificationID)));
}
}
+ ClearIDCache();
+
String ihost, iport, iuser, ipasswd, idb;
const char *host, *port, *user , *passwd, *db;
return it->second;
}
+void DbConnection::ClearIDCache(void)
+{
+ m_ObjectIDs.clear();
+ m_InsertIDs.clear();
+}
+
void DbConnection::SetConfigUpdate(const DbObject::Ptr& dbobj, bool hasupdate)
{
if (hasupdate)
void SetInsertID(const DbObject::Ptr& dbobj, const DbReference& dbref);
DbReference GetInsertID(const DbObject::Ptr& dbobj) const;
+ void ClearIDCache(void);
+
void SetConfigUpdate(const DbObject::Ptr& dbobj, bool hasupdate);
bool GetConfigUpdate(const DbObject::Ptr& dbobj) const;