Unable to Connect from my host Container(Linux) to sql server (AWS EC2)

Hi Team,
i am facing issue while connecting to my sql server on AWS EC2 from my local linux container.
I am using a sample nginx Container and through it i am simply installing the telnet utility.
below is the command used

docker pull nginx

docker run -dp 80:80 nginx

Now i am able to telnet from my system to the target machine on port 1433 , but it is not behaving the same from my linux container.

Error Message :telnet: Unable to connect to remote host: No route to host

I am using
Docker Desktop :4.6.1
Engine: 20.10.13
Compose 1.29.2