472,342 Members | 1,327 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,342 software developers and data experts.

Records in hirarchial

kiss07
99
Hi,

In employee table i want to display records in hirarchial
order.How can i do it..I want query.Hirarchial means follwing:

Personal Manager
----Manager
-----Team Leader
------Team Member
--------Tester..

Its Ok.Anybody ..Pls

Regards,
Arun..
May 3 '07 #1
4 1083
frozenmist
179 Expert 100+
Hi,

In employee table i want to display records in hirarchial
order.How can i do it..I want query.Hirarchial means follwing:

Personal Manager
----Manager
-----Team Leader
------Team Member
--------Tester..

Its Ok.Anybody ..Pls

Regards,
Arun..

You can do it if there is a column to identify the level
May 3 '07 #2
debasisdas
8,127 Expert 4TB
Expand|Select|Wrap|Line Numbers
  1. COLUMN EMPLOYEE FORMAT A20
  2.  
  3. SELECT LEVEL,LPAD(' ',2*(LEVEL-1))||ENAME "EMPLOYEE" ,EMPNO,MGR FROM EMP
  4. START WITH MGR IS NULL CONNECT BY PRIOR EMPNO=MGR
  5.  
  6.  
Please try the above code in SCOTT schema on EMP table...
May 3 '07 #3
kiss07
99
Dear deba,

Thanku very much.

Arun
May 3 '07 #4
debasisdas
8,127 Expert 4TB
Dear Arun

U are always welcome

But why u want code everytime in all your posts.

try somthing by yourself.

If u can't solve it then only post in forum.

Debasis
May 3 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: tom | last post by:
I am new to SQL administration. >From a list of IDs that are the primary key in one table (i.e. Customer Table), I want to make changes in tables...
3
by: CSDunn | last post by:
Hello, I have an Access 2000 Project in which the data comes from a SQL Server 2000 database, and multiple users need to be able to see new records...
1
by: Liz | last post by:
I have a table of about 10,000 records where each record has a numeric field named RecIdent. The value of RecIdent starts at 1 and is not...
6
by: Paul T. Rong | last post by:
Dear all, Here is my problem: There is a table "products" in my access database, since some of the products are out of date and stopped...
5
by: Grant | last post by:
Hi Is there a way to recover deleted records from a table. A mass deletion has occurred and Access has been closed since it happened Louis
13
by: Jan | last post by:
Hi I have a database that I use to keep track of the sales promotions that we send to companies. I normally send a mailing based on a subset...
1
by: KC | last post by:
Hello, I am using Access 2002. WinXP, Template from MS called Orders Mgmt DB. I have tweaked this DB to work for our small co. It has worked...
4
by: LetMeDoIt | last post by:
Greetings, I'm using ASP to retrieve from MSSQL and I then populate a table. After several months of successfull retrieves, this same code now...
11
by: shriil | last post by:
Hi I have this database that calculates and stores the incentive amount earned by employees of a particular department. Each record is entered...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...
0
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.