Click here to Skip to main content
15,883,535 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: vsnprintf() Pin
norish14-Sep-09 7:32
norish14-Sep-09 7:32 
AnswerRe: vsnprintf() Pin
Joe Woodbury14-Sep-09 8:08
professionalJoe Woodbury14-Sep-09 8:08 
AnswerRe: vsnprintf() Pin
Member 419459314-Sep-09 9:07
Member 419459314-Sep-09 9:07 
QuestionI have to insert value into table at runtime ? Pin
jadhavjitendrar14-Sep-09 0:26
jadhavjitendrar14-Sep-09 0:26 
AnswerRe: I have to insert value into table at runtime ? Pin
«_Superman_»14-Sep-09 0:44
professional«_Superman_»14-Sep-09 0:44 
GeneralRe: I have to insert value into table at runtime ? Pin
jadhavjitendrar14-Sep-09 0:48
jadhavjitendrar14-Sep-09 0:48 
GeneralRe: I have to insert value into table at runtime ? Pin
jadhavjitendrar14-Sep-09 2:24
jadhavjitendrar14-Sep-09 2:24 
QuestionRe: I have to insert value into table at runtime ? Pin
norish14-Sep-09 8:30
norish14-Sep-09 8:30 
When strAnsi has _T("aaa\nbbb\nccc") then want to make 3 records?
Do you mean like this?

If then, you must split strAnsi at first and make and execute sql 3 times.

For example;
TCHAR* strData = strAnsi.GetBuffer(-1);
TCHAR* pToken = _tcstok(strAnsi, _T("\n"));
while (pToken) {
  CString sql;
  sql.Format(_T("INSERT INTO tablename (%s) VALUES('%s')"), setid, pToken);
  // execute SQL here
}
strAnsi.ReleaseBuffer();


Well, I dont feel good VALUES('%s') in above sql because of string
escaping issue or SQL-injection problems.
I usually use prepared statements or parameterized query for this purpose.
QuestionRe: I have to insert value into table at runtime ? Pin
CPallini14-Sep-09 0:45
mveCPallini14-Sep-09 0:45 
Questionneed help for programming PTZ camera Pin
rajapp13-Sep-09 23:09
rajapp13-Sep-09 23:09 
QuestionCut Rectangles in images Pin
Game-point13-Sep-09 22:14
Game-point13-Sep-09 22:14 
AnswerRe: Cut Rectangles in images Pin
CPallini13-Sep-09 22:55
mveCPallini13-Sep-09 22:55 
AnswerRe: Cut Rectangles in images Pin
Game-point13-Sep-09 23:26
Game-point13-Sep-09 23:26 
QuestionHOw can run vlc code Pin
anishkannan13-Sep-09 21:23
anishkannan13-Sep-09 21:23 
AnswerRe: HOw can run vlc code Pin
CPallini13-Sep-09 21:48
mveCPallini13-Sep-09 21:48 
AnswerRe: HOw can run vlc code Pin
Michael Schubert13-Sep-09 21:52
Michael Schubert13-Sep-09 21:52 
GeneralRe: HOw can run vlc code Pin
enhzflep14-Sep-09 4:18
enhzflep14-Sep-09 4:18 
QuestionReg XML reading Pin
hellogany13-Sep-09 21:07
hellogany13-Sep-09 21:07 
AnswerRe: Reg XML reading Pin
Nuri Ismail13-Sep-09 21:20
Nuri Ismail13-Sep-09 21:20 
GeneralRe: Reg XML reading Pin
kilt14-Sep-09 2:14
kilt14-Sep-09 2:14 
GeneralRe: Reg XML reading Pin
Nuri Ismail14-Sep-09 3:32
Nuri Ismail14-Sep-09 3:32 
GeneralRe: Reg XML reading Pin
David Crow14-Sep-09 4:08
David Crow14-Sep-09 4:08 
GeneralRe: Reg XML reading Pin
Nuri Ismail14-Sep-09 4:19
Nuri Ismail14-Sep-09 4:19 
GeneralRe: Reg XML reading Pin
CPallini14-Sep-09 10:36
mveCPallini14-Sep-09 10:36 
QuestionHow to Resize BMP image in C Pin
LoveneetSingh13-Sep-09 20:52
LoveneetSingh13-Sep-09 20:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.