MCPcopy Create free account
hub / github.com/codestation/qcma / insertNodeEntry

Method insertNodeEntry

common/sqlitedb.cpp:500–515  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

498}
499
500int SQLiteDB::insertNodeEntry(const QString &title, int type, int data_type)
501{
502 QSqlQuery query;
503
504 query.prepare("INSERT INTO object_node (type, data_type, title) VALUES (:type, :data_type, :title)");
505 query.bindValue(0, type);
506 query.bindValue(1, data_type);
507 query.bindValue(2, title);
508
509 if(!query.exec() || !query.exec("SELECT last_insert_rowid()") || !query.next()) {
510 qDebug() << query.lastError();
511 return 0;
512 }
513
514 return query.value(0).toInt();
515}
516
517bool SQLiteDB::insertSourceEntry(uint object_id, const QString &path, const QString &name)
518{

Callers

nothing calls this directly

Calls 1

valueMethod · 0.80

Tested by

no test coverage detected