Optimizations around sequence ID