GET_IDCARD_AGE

更新时间:
复制 MD 格式

The GET_IDCARD_AGE function validates an ID card number and returns the current age of the cardholder.

Syntax

get_idcard_age(<idcardno>)

Parameters

Parameter Required Type Description
idcardno Yes STRING A 15-digit or 18-digit ID card number. The function validates the number by checking the province code and the last digit. Returns null if validation fails.

Return value

Returns a BIGINT value. Returns null if the input is null.

References