Retrieving tree structure data from database using java script framework

Hello,

I have  Attached a docs, Let me know how i am going to  read from the database  recursively and represent  a tree structure in  any of the java script framework  ..Any other suggestion would be appreciated...

Thanks
Tables_structure.doc
roy_sanudeveloperAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Julian HansenCommented:
What is the target environment?

A JavaScript script running in a browser cannot access a database directly other than through a server side process.

Give us more information about what you are doing and we can take it from there.
Rainer JeschorCommented:
Hi,

one possible solution (there are multiple but I am a MS "branded" guy) would be to use a combo of node.js as JavaScript server-side engine, to get the data - more info e.g. here:
http://blogs.msdn.com/b/sqlphp/archive/2015/05/12/getting-started-with-node-js-and-microsoft-sql-server-and-azure-sql-database.aspx
Then get the data into two JSON arrays - one containing the unique objects and additional attributes and one containing the parent-child relationship -  and then use a charting library like D3 to display the result.

Just my 2 ct

Rainer
roy_sanudeveloperAuthor Commented:
Hi Julian

Our target environment is j2ee open source... and oracle is the databases.can you suggest how can that be achieved

Thanks
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

gurpsbassiCommented:
I would simply return your data structure in JSON form to your view and then use a jQuery tree  plugin (there are many on the web you can choose from) to build the tree on the client side.
roy_sanudeveloperAuthor Commented:
Well, I assume you are referring to build sql query tree structure using JSON. I am not clear about it..
Can you sent me piece of code..
gurpsbassiCommented:
No I was commenting on the client side rendering the tree.

You need to create a domain model first to hold your data in hierarchial form. I'll see if I got some time to look at it later today.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
roy_sanudeveloperAuthor Commented:
thanks  i have completed the task
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
JavaScript

From novice to tech pro — start learning today.