Let #f(x)=(x-2)/(x+1)#
We build a sign chart
#color(white)(aaaa)##x##color(white)(aaaa)##-oo##color(white)(aaaaaa)##-1##color(white)(aaaaaa)##2##color(white)(aaaaaaa)##+oo#
#color(white)(aaaa)##x+1##color(white)(aaaaa)##-##color(white)(aaaa)##||##color(white)(aa)##+##color(white)(aa)##0##color(white)(aaa)##+#
#color(white)(aaaa)##x-2##color(white)(aaaaa)##-##color(white)(aaaa)##||##color(white)(aa)##-##color(white)(aa)##0##color(white)(aaa)##+#
#color(white)(aaaa)##f(x)##color(white)(aaaaaa)##+##color(white)(aaaa)##||##color(white)(aa)##-##color(white)(aa)##0##color(white)(aaa)##+#
Therefore,
#f(x)<=0# when #x in (-1,2]#
graph{(x-2)/(x+1) [-14.24, 14.24, -7.12, 7.12]}