Welcome Guest, Not a member yet? Register   Sign In
Please..... Help....
#1

[eluser]Bluemagix[/eluser]
Hello,
I have table called category
having fields, records like this

id name parentid
1 Bank 0
2 Shopping 0
3 Axis 1
4 ICICI 1
5 SBI 1
6 Nike 2
7 xyz 2

where parentid 0 means major categories.
and for other is shows the sub category according to parentid

Eg: icici's parentid is 1 because it comes under bank [having id]

Now, i want result as
Bank
Axis
ICICI
SBI
Shopping
Nike
xyz


How can i do that??
which query i should use??


Messages In This Thread
Please..... Help.... - by El Forum - 02-02-2009, 04:43 AM
Please..... Help.... - by El Forum - 02-02-2009, 09:53 AM



Theme © iAndrew 2016 - Forum software by © MyBB