Code: Select all
with dm.QAct do
begin
close;
sql.Clear;
sql.Text:='insert into PEMINJAMAN(TRANSID,FAKTUR,IDBUKU,IDMEMBER,TGLPINJAM,TGLKEMBALI,IDPETUGAS,JUMLAH) values(:transid,:faktur:idbuku,:idmember,:tglpinjam,:tglkembali,:idpetugas,:jumlah)';
parambyname('transid').asstring:=transid;
Parambyname('faktur').asstring:=flatedit1.Text;
ParamByName('idbuku').asstring:=advstringgrid1.Cells[0,i];
ParamByName('idmember').asstring:=flatedit2.text;
ParamByName('tglpinjam').asdate:=strtodate(flatedit4.text);
ParamByName('tglkembali').asdate:=strtodate(flatedit5.Text);
ParamByName('idpetugas').asstring:=idptgs;
params.ParamByName('jumlah').asinteger:=strtoint(advstringgrid1.Cells[2,i]);
execSQL;
end;
end;
where my wrong code?i use firebird for database.