Рекомендована публікація

неділя, 16 березня 2014 р.

mysql

is soooooooooo sweet, it draws some kinda little bars for me on show tables; !!! :D

mysql> show tables;
+------------------------+
| Tables_in_thevery1stdb |
+------------------------+
| thev1sttableever       |
+------------------------+
1 row in set (0.00 sec)
And Scooby-doo is damn so scary, even when I'm grown up, it's hella scary!

And it also says "Bye"!!!
yup, my first IDE-DBMS interaction!!

QSqlDatabase db = QSqlDatabase::addDatabase("QMYSQL");
   db.setHostName("localhost");
   db.setDatabaseName("test");
   db.setUserName("niam");
   db.setPassword("1111");
   bool ok = db.open();
   qDebug() << db.lastError().text();
   assert(ok);

   QSqlQuery query;
   //query.exec("CREATE TABLE NEW(id int)");
   query.exec("SHOW TABLES");
   if(query.next()){
        QString res = query.value(0).toString();
        qDebug() << res;

        qDebug() << "yes";


No, meal, NO!! Why do you mess everything up!?! I want to code, not to eat!

Немає коментарів:

Дописати коментар