All Products
Search
Document Center

MaxCompute:GET_IDCARD_AGE

Last Updated:Feb 28, 2024

The GET_IDCARD_AGE function of MaxCompute checks the validity of the ID card and returns the current age based on the ID card number. This topic describes the syntax and parameters of the GET_IDCARD_AGE function.

Syntax

get_idcard_age(<idcardno>)

Parameters

idcardno: required. A 15-digit or 18-digit ID card number of the STRING type. During calculation, the validity of the ID card is checked based on the province code and the last digit of the ID card number. If the check fails, null is returned.

Return value

A value of the BIGINT type is returned. If the input parameter is set to null, the return value is null.

References