what is use of self join and which cases you will use this join
Answer / vidhya
A physical file can be joined to itself to read records that are formed by combining two or more records from the PF itself.
For example
You use a self join when a table references data in itself.
E.g., an Employee table may have a SupervisorID column that points to the employee that is the boss of the current employee.
To query the data and get information for both people in one row, you could self join like this:
select e1.EmployeeID,
e1.FirstName,
e1.LastName,
e1.SupervisorID,
e2.FirstName as SupervisorFirstName,
e2.LastName as SupervisorLastName
from Employee e1
left outer join Employee e2 on e1.SupervisorID = e2.EmployeeID
Is This Answer Correct ? | 0 Yes | 0 No |
How to insert more than one record to a pf at a time?(Bulk insert to a pf)
what is the difference between adding keys & constraints into a phisical file
what is error handling concepts in cl
Define interactive jobs and batch jobs
Which keyword is used both in subfile and subfile control record format of a DSPF?
How to update physical file using logical file with example?
What is the interactive job?
Can we concatenate fields in physical file? If yes how can we do?
What is the primary file?
In how many ways we can create a logical file?`
When we use any keyword like FIFO,LIFO, at file level but whenever we check by runqry we couldn't find answer in FIFO,LIFO,FCFO etc so how we check the answer.
what is general and type of general