TEXT TO lcSQL NOSHOW INSERT INTO tbl_MP3 ([Foreign Key_Folder],Filename, ConvertDate,file_date,Filesize) VALUES (?config.Folder_ig,?laWavs[j,1],?DATE(),?.....) ENDTEXT IF SQLExec(lnHandle,lcSQL) < 0 IF AERROR(laError) > 0 Messagebox("Error appening:"+laError[2]) ENDIF ENDIF>Hi probably an easy question for someone that has been doing this for awile. I have a routine that scans a directory and then converts WAV file to MP3's then i need to load the info into a SQL server table. Anyways below is a snippet of the code ..x = -1 so it is not updating the sql table.
lcsql = 'Insert into tbl_Mp3 (Foreign Key_folderID, filename, ConvertDate, filedate, filesize) VALUES(' + alltrim(config.folder_id)+ ',' + lawavs(j,1) +','+ dtoc(date())+ ',' + dtoc(lawavs(j,3))+ ','+ alltrim(str(lawavs(j,2))) + ')' x = SQLEXEC(nHandle,lcsql) ?lcsql ?x