Scalar Posterior Sampling with Applications