category tbl
cat_id name type
1 cloths boy
2 cloth girs
3 bags boy
4 bags girls
sub cat. tbl
subcat_id cat_id subcat_name
1 (?) jeans
Now in subcategory table I want to get cat_id.
In subcategory form user can select category->cloth and cat_type->boys... Then I want to add that category id in subcategory table.