Home » U++ Library support » U++ SQL » PostgreSQL NaN fetching from DB
PostgreSQL NaN fetching from DB [message #50095] |
Thu, 26 July 2018 16:33 |
shutalker
Messages: 15 Registered: November 2017 Location: Moscow
|
Promising Member |
|
|
Hi!
I've noticed that NaN floating point values fetches from DB as zero values because of using Atof(). There is no possibility to check whether the value is NaN or not via such functions like IsNaN() or IsNull(). Also I have a question about fetching integers: why atoi() call is used in this code, and not ScanInt()?
void PostgreSQLConnection::GetColumn(int i, Ref f) const
{
...
switch(info[i].type)
{
...
case INT_V:
f.SetValue(atoi(s));
break;
...
}
...
}
Here is a patch in attachments. Could you check and comment it?
[Updated on: Sat, 04 August 2018 11:31] Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Thu Apr 18 07:44:42 CEST 2024
Total time taken to generate the page: 0.02026 seconds
|