format_grid_data rewrite done