Topic: cf field not showing 2 decimals
Hi,
what i do wrong , field type currency not showing 2 decimals.
printf("%.2f",
(SELECT sum(Total) FROM TableLines WHERE id_TableOrders = TableOrders.id)
) My Visual Database → General → cf field not showing 2 decimals
Hi,
what i do wrong , field type currency not showing 2 decimals.
printf("%.2f",
(SELECT sum(Total) FROM TableLines WHERE id_TableOrders = TableOrders.id)
) functions are processed within the SELECT command
(
SELECT printf("%.2f", sum(Total) ) FROM TableLines WHERE id_TableOrders = TableOrders.id)
) Hi,
i use your code but still not showing 2 decimals
You try chose Field type (TEXT) in CfTotal not Real
the result like this 315.00
Hi
thank you for answer, i try it but nothing cannot get decimals
here is screenshot
I send fixed file your project
Hi,
thank you but again nothing![]()
in calculate field file Type choose type (TEXT) don.t CURRENCY
ohhh, thank you
Hi
now when i change to text sum not working then,look at screenshot
Hi Igor, Hi Agusecc,
Works perfectly for me - deleted invoices, added new orders / invoices, tested for displaying 9.99, 9.90 and 9.00 and everything appears correct (see attached).
Derek.
Hi Derek, Agusecc, k245
There is no error in the calculated field.
I have a different decimal separator. There is indeed a difference.
He can use:
procedure FormMain_TableGridInvoices_OnChange (Sender: TObject);
begin
TNxNumberColumn(FormMain.TableGridInvoices.Columns[9]).FormatMask := '#,##0.00';
end;And I think you can do without printf in the calculated field.
Hi all,
very nice sparrow, this works
Thank you all
Hi Sparrow,
You have excellent eye-sight to spot the ',' instead of '.'! ![]()
Derek.
Hi Sparrow,
You have excellent eye-sight to spot the ',' instead of '.'!
Derek.
This is only in glasses )))))))) And they still need to be found ))))
But seriously, these periods and commas like to present surprises in our regional standards.
My Visual Database → General → cf field not showing 2 decimals
Powered by PunBB, supported by Informer Technologies, Inc.
Theme Hydrogen by Kushi