Toy Story was released in 1995. Shrek was released in 2001. Therefore, Toy Story came out six years earlier.