[cvsnt] Re: Help with Audit

Torsten Martinsen torsten at vip.cybercity.dk
Wed Feb 15 21:57:03 GMT 2006


Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.


Bo Berglund wrote:

>g_pDb->Execute("Insert Into %sCommitLog (SessionId, Directory,
>Message, Type, Filename, Tag, BugId, OldRev, NewRev, Added, Removed,
>Diff) Values (%lu, '%s', ? ,'%c','%s','%s','%s','%s','%s',%lu, %lu, ?
>)",g_szPrefix,g_nSessionId,NULLSTR(directory),change_list[n].type,
>NULLSTR(change_list[n].filename),NULLSTR(change_list[n].tag),
>NULLSTR(change_list[n].bugid),NULLSTR(change_list[n].rev_old),
>NULLSTR(change_list[n].rev_new),added,removed);
>
>Seems to me that the Message item is missing from the argument list
>(should be betweeen directory and type). I really do not understand
>this strange syntax...
>  
>
Lines 250-251

            g_pDb->Bind(0,message?message:"");
            g_pDb->Bind(1,diff);

cause 'message' to be bound to the first '?' in the SQL statement, and 
'diff' to the second '?'.

So no, Message is not missing - I would assume that these two fields are 
BLOBs, and that's why they aren't passed directly in the SQL.

-Torsten



More information about the cvsnt mailing list
Download the latest CVSNT, TortosieCVS, WinCVS etc. for Windows 8 etc.
@CVSNT on Twitter   CVSNT on Facebook