Subject | Re: [firebird-support] firebird - post with changed TBlobField is very slow |
---|---|
Author | Martijn Tonies |
Post date | 2004-12-08T21:00:48Z |
Hi,
the blob into the parameter, call Execute.
Don't use .Post and .Edit.
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server
Upscene Productions
http://www.upscene.com
> I use Firebird with BDE.Do an INSERT INTO, prepare the statement, load
> In my program I want to save a TBlobField which is working. But if
> the
> file will be bigger than 20k it will take some minutes if the
> post-call
> will return.
>
> In BDE I use BLOB SIZE = 4000
> BLOBS TO CACKE = 4000
>
> The code looks like:
>
> meinVTDataModule.LZA_VERSION.Filter := 'lzanr = ' +
> IntToStr(lza.m_id)
> + ' and new_version = ' + versionNr + ' and new_status = ''' +
> status +
> '''';
> meinVTDataModule.LZA_VERSION.Filtered := TRUE;
> meinVTDataModule.LZA_VERSION.Open();
> meinVTDataModule.LZA_VERSION.Edit();
>
> TBlobField(meinVTDataModule.LZA_VERSION.FieldByNam
> e('ZIP_BLOB')).LoadFromFile(archivDir
> + '.zip');
>
> // the next line ist very slow
> meinVTDataModule.LZA_VERSION.Post();
>
> meinVTDataModule.LZA_VERSION.Close();
> Is there a way to make the Post faster?
the blob into the parameter, call Execute.
Don't use .Post and .Edit.
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server
Upscene Productions
http://www.upscene.com