format and extract constant