• This forum is the machine-generated translation of www.cad3d.it/forum1 - the Italian design community. Several terms are not translated correctly.

adolisp library: precision after the unrespected comma

  • Thread starter Thread starter acitano
  • Start date Start date

acitano

Guest
Bye to all,
I am using the famous adolisp_library.lsp library of ms. jonh fleming.
I am questioning a table of a db of access 2007 with numerical fields that contain numbers like these:

200345.34289
79234.587
1024.12
30.05.56
etc.

when I run the sqlstatement:
(setq sqlstatement "select" from [mytable]"
I am returned:

200345.3
79234.6
1024.12
30.05.56

I don't understand why with the fourth number the three decimals are returned to the right while for the first two no!
I don't understand why with the third number two decimals are returned to me!
I believe that if the number is larger than 5 digits on the left adolisp_library truncates to one digit after the comma
I need the three decimal digits to the right also of the first 3 numbers (200345.34289 - 79234.58755 - 1024.123) without truncating them, how do I do?
thanks acitano
 
"....the real numbers are stored in double-precision mobile comma format, providing at least 14 significant precision figures, despite compaiano solo 6 in the autocad command line area.":smile:
 
thanks gp,
I should have thought about it before, this is just a novice mistake of the lisp.
I even put my hands in the adolisp_library code.
I checked with the rtos function:
Code:
(number 2 14)
to revert the number imported into string by welcoming 14 decimals and works perfectly.
Sometimes you don't have to trust what you see, but go a little further.

Thank you very much
acitano:finger:
 

Forum statistics

Threads
44,997
Messages
339,767
Members
4
Latest member
ibt

Members online

No members online now.
Back
Top