MySQL is installed, but it is NOT added to Windows PATH Let’s fix it step-by-step (no confusion)

 đŸ‘‰ MySQL is installed, but it is NOT added to Windows PATH

Let’s fix it step-by-step (no confusion).


✅ OPTION 1 (FASTEST – works immediately)

1️⃣ Find MySQL bin folder

Usually here:

C:\Program Files\MySQL\MySQL Server 8.0\bin

Inside this folder, you should see:

mysql.exe

2️⃣ Run MySQL using FULL PATH

In Command Prompt, run:

"C:\Program Files\MySQL\MySQL Server 8.0\bin\mysql.exe" -u root -p

✔ This will work even without PATH setup


✅ OPTION 2 (PERMANENT FIX – RECOMMENDED)

This allows you to run mysql from anywhere.

1️⃣ Copy MySQL bin path

C:\Program Files\MySQL\MySQL Server 8.0\bin

2️⃣ Add to PATH

  1. Press Windows + R

  2. Type:

    sysdm.cpl
  3. Go to Advanced tab

  4. Click Environment Variables

  5. Under System variables, select Path

  6. Click Edit

  7. Click New

  8. Paste:

    C:\Program Files\MySQL\MySQL Server 8.0\bin
  9. Click OK → OK → OK


3️⃣ Restart Command Prompt

Close cmd, open again.

Run:

mysql --version

You should see:

mysql Ver 8.0.xx for Win64

Now try:

mysql -u root -p

đŸ”‘ If root login fails

Try:

mysql -u admin -p -h database-1.c96awkikufpe.ap-south-1.rds.amazonaws.com -P 3306

(Remember: AWS RDS does NOT allow local root login)


đŸ§  Quick check

Run this and tell me output:

where mysql

Post a Comment

0 Comments