C++ (Qt)void Connection::generateString(string *generateString){ stringstream generatedString; time_facet *pfacet = new time_facet("%d-%b-%Y %H:%M:%S"); generatedString.imbue(locale(locale::classic(), pfacet)); generatedString << setprecision(8) << "INSERT INTO SOME_TABLE VALUES ( 0, " << static_cast<uint32_t>(m_session.id) << ", '" << boost::posix_time::from_time_t(m_session.timeStamp) << "', " << static_cast<uint32_t>(m_session.someValue) << ");"; *generateString = generatedString.str();}
C++ (Qt)*generateString = "Some text";
C++ (Qt)boost::posix_time::from_time_t(m_session.timeStamp)
C++ (Qt)sprintf(timestamp, "%02d-%s-%04d %02d:%02d:%02d", time->tm_mday, mon[time->tm_mon], 1900+time->tm_year, time->tm_hour, time->tm_min, time->tm_sec);