Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
-
None
Description
In Multinomial Logistic Regression, It's fairly good that mlogr could use utf8 characters as schema name and table name. But when we use utf8 character as column name, It encounters an error.
Test Environment:
GPDB version: PostgreSQL 8.2.15 (Greenplum Database 4.2.2.0 build 6) on x86_64-unknown-linux-gnu, compiled by GCC gcc (GCC) 4.4.2 compiled on Jul 1 2012 11:15:14 MADlib version: 0.4.1, git revision: v0.4.1-37-g57a362e, cmake configuration time: Thu Sep 6 09:15:06 UTC 2012, build type: RelWithDebInfo, build system: Linux-2.6.18-194.11.3.el5, C compiler: gcc 4.1.2, C++ compiler: gcc 4.1.2
Test Data:
\d madlibtestdata.testtable Table "madlibtestdata.testtable" Column | Type | Modifiers --------------------------------+--------------------+----------- id | integer | x | double precision[] | ~!@#$%^*()_+-=:{[}]|,.?/Column | integer | Distributed by: (id) select * from madlibtestdata.testtable ; id | x | ~!@#$%^*()_+-=:{[}]|,.?/Column ----+---------+-------------------------------- 1 | {1,1,2} | 0 1 | {1,2,3} | 1 1 | {1,3,4} | 2 (3 rows)
Test Result:
select * from madlib.mlogregr ( 'madlibtestdata.testtable', 'U&"~!@#$%^*()_+-=:{[}]|,.?/Column"', '3','x','20','irls','0.0001'); ERROR: ValueError: empty field name (plpython.c:4648) CONTEXT: Traceback (most recent call last): PL/Python function "compute_mlogregr", line 27, in <module> return multilogistic.compute_mlogregr(**globals()) PL/Python function "compute_mlogregr", line 178, in compute_mlogregr PL/Python function "compute_mlogregr", line 96, in __runIterativeAlg PL/Python function "compute_mlogregr" SQL statement "SELECT ( SELECT madlib.compute_mlogregr( $1 , $2 , $3 , $4 , $5 , $6 , $7 ) )" PL/pgSQL function "mlogregr" line 6 at assignment