Hello friend ,
I am doing a project where 1st dropdown value populates the second drop down menu.
i have a table with three columns id, length and breadth with values as
id length breadth
1 72 36
2 74 30
3 76 28
4 78 25
How to write a mysql query with selected value at first and remaining after that i.e, if i select length 76 the second drop down menu must contain 28 and remaning all values like this
1st menu 2nd menu
length breadth
76 28
72 36
74 30
78 25
I wrote the code in Ajax but i require the query for this.
Please anyone help me.
mysql query select * from....
Moderator: General Moderators
- jaoudestudios
- DevNet Resident
- Posts: 1483
- Joined: Wed Jun 18, 2008 8:32 am
- Location: Surrey
Re: mysql query select * from....
Something like this...
Code: Select all
SELECT * FROM [table] WHERE length = 76