mindmap-search3 Project 마감 :-) 보호되어 있는 글 입니다. 2009. 3. 18. [Sqlite3] Query문 사용시, c_str()사용 char szTemp[1024] = {0,}; // char* 선언시, 메모리를 참조하지 못할 수도 있으므로 char type을 사용한다. char sQuery[1024] = {0,}; QueryA : - sprintf(szTemp, _T("insert into IndexDB(IndexID, FileName, weight) values ( (SELECT IndexID FROM Dictionary where word = '%s'), '%s', 0);"), s_Word.c_str(), szFilename.c_str()); QueryA Execute : - m_dbMindmap.execQuery(szTemp); QueryB : - sprintf(sQuery, _T("select indexID from Dict.. 2009. 3. 17. SQLite3_ Autoincrement생성 방법 (1) How do I create an AUTOINCREMENT field. Short answer: A column declared INTEGER PRIMARY KEY will autoincrement. Here is the long answer: If you declare a column of a table to be INTEGER PRIMARY KEY, then whenever you insert a NULL into that column of the table, the NULL is automatically converted into an integer which is one greater than the largest value of that column over all other rows i.. 2009. 3. 16. 이전 1 다음