Changeset 5d9409d for src/sql


Ignore:
Timestamp:
03/03/10 16:47:00 (12 years ago)
Author:
timkoma <timkoma@…>
Branches:
master, qt5
Children:
5bd6aba
Parents:
7270ae0
Message:

UTC/LocalTime fix for import conference XML, DB queries for multiple conferences fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sql/sqlengine.cpp

    r7270ae0 r5d9409d  
    153153            /*qDebug() << QString("DEBUG: Track %1 added to DB").arg(name);*/
    154154        }
    155         QDateTime startDateTime = QDateTime(QDate::fromString(aEvent["date"],DATE_FORMAT),QTime::fromString(aEvent["start"],TIME_FORMAT));
     155        QDateTime startDateTime;
     156        startDateTime.setTimeSpec(Qt::UTC);
     157        startDateTime = QDateTime(QDate::fromString(aEvent["date"],DATE_FORMAT),QTime::fromString(aEvent["start"],TIME_FORMAT),Qt::UTC);
     158        qDebug() << "startDateTime: " << startDateTime.toString();
    156159        QString values = QString("'%1', '%2', '%3', '%4', '%5', '%6', '%7', ? , ? , ? , ? , ? , '%8', '%9'") \
    157160                         .arg(aEvent["conference_id"]) \
     
    169172            .arg(values);
    170173
     174        qDebug() << query;
    171175        QSqlQuery result;
    172176        result.prepare(query);
     
    369373    execQuery( db, query );
    370374
    371     //TODO: retun number of rows from SEARCH_EVENT
    372375    return 1;
    373376}
Note: See TracChangeset for help on using the changeset viewer.