[fpc-devel] TFmtBCDField

Joost van der Sluis joost at cnoc.nl
Tue Feb 22 22:57:41 CET 2011


On Mon, 2011-02-21 at 09:22 +0100, LacaK wrote:
> 1. VarFMTBcdCreate() should already work, so:

Done

> 2. VarToBCD() is already implemented, so:

Done

> 3. BCDToStrF there is waiting patch 
> http://bugs.freepascal.org/view.php?id=18388 if applied, then also can 
> be removed comments in procedure TFMTBCDField.GetText

I'll leave this bug open for Marco.

> 4. Add 3th parameter to TryStrToBCD( const aValue : FmtBCDStringtype;  
> var BCD : tBCD;  DecimalSeparator : char = #0) : Boolean;
> so we can supply directly decimal separator '.' used in SQL and to avoid 
> saving existing, set '.' and then restoring ... 
> http://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/packages/fcl-db/src/sqldb/sqlite/sqlite3conn.pp?r1=16948&r2=16954
> (like TryStrToDate, TryStrToTime)
> or
>  add overloaded TryStrToBCD( const aValue : FmtBCDStringtype;  var BCD : 
> tBCD;  FormatSettings : TFormatSettings) : Boolean;
> (like TryStrToFloat)

And could you add a bug-report for this? I think that Marco or MvC
should have a look at it and have to decide which design is best and
also compatible to Delphi. Then the db-changes can be made.

Joost




More information about the fpc-devel mailing list