Up Prev Next
From: arthur at puma dot mt dot att dot com (Arthur Goldstein)
Subject: numerics and db-lib
Date: Jan 20 1999 3:41AM
When retreiving numeric data it is returned as a string with many spaces
after it when
using dblib, but not ctlib. How can one get it to return a proper
I.e. within table_t column_c is defined as numeric(10).
$db->dbcmd("select column_c from table_t");
($value) = ($db->dbnextrow());
Might result in
as opposed to '1'.
ct-lib seems to behave as desired.
(Current solution is to redo the sql as:
$db->dbcmd("select convert(int, column_c) from table_t") which doesn't