make sure sid is always unique