[ https://issues.apache.org/jira/browse/FLINK-21412?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dian Fu updated FLINK-21412: ---------------------------- Fix Version/s: 1.12.3 1.13.0 > pyflink DataTypes.DECIMAL is not available > ------------------------------------------ > > Key: FLINK-21412 > URL: https://issues.apache.org/jira/browse/FLINK-21412 > Project: Flink > Issue Type: Bug > Components: API / Python > Affects Versions: 1.12.1 > Environment: python 3.7.5 > pyflink 1.12.1 > Reporter: awayne > Assignee: Dian Fu > Priority: Critical > Labels: pull-request-available > Fix For: 1.13.0, 1.12.3 > > > when i use DataTypes.DECIMAL in udaf > File > "/home/ubuntu/pyflenv/lib/python3.7/site-packages/pyflink/table/types.py", > line 2025, in _to_java_data_type > _to_java_data_type(data_type._element_type)) > File > "/home/ubuntu/pyflenv/lib/python3.7/site-packages/pyflink/table/types.py", > line 1964, in _to_java_data_type > j_data_type = JDataTypes.Decimal(data_type.precision, data_type.scale) > File > "/home/ubuntu/pyflenv/lib/python3.7/site-packages/py4j/java_gateway.py", line > 1516, in __getattr__ > "\{0}.\{1} does not exist in the JVM".format(self._fqn, name)) > py4j.protocol.Py4JError: org.apache.flink.table.api.DataTypes.Decimal does > not exist in the JVM > > in pyflink\table\types.py > line 1963-1964 > elif isinstance(data_type, DecimalType): > j_data_type = > JDataTypes.{color:#FF0000}Decimal{color}(data_type.precision, data_type.scale) > in java should be called "DECIMAL" -- This message was sent by Atlassian Jira (v8.3.4#803005)