Added fid_counter to SQL file