Ebay Interview Question for Member Technical Staffs


Country: India
Interview Type: In-Person




Comment hidden because of low score. Click to expand.
5
of 5 vote

select Emp_id,Emp_name,Emp_email into newtable from Employee
group by Emp_id,Emp_name,Emp_email
having count(*)>1;

delete from Employee
where Emp_id,Emp_name,Emp_email in newtable;

insert into Employee
select Emp_id,Emp_name,Emp_email from newtable;

- zyfo2 January 29, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
5
of 5 vote

delete *
from (select * from emp MINUS select distinct(emp_id, emp_name, emp_mailid) from emp)

- MZ April 26, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 votes

cool...

- PKT October 04, 2014 | Flag
Comment hidden because of low score. Click to expand.
1
of 1 vote

delete from employee e1 where e1.rowid in
(
select e2.rowid from employee e2 where
e1.empid = e2.empid and
e1.rowid > e2.rowid
)

- Mustaq Choudhari February 06, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

sort on empid key and compare

- bbarodia January 29, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

delete from Employee where rowid in (
  select rid from (
    select rowid rid, 
           row_number() over(partition by id,name,email order by id,name,email) as idx 
    from tab7)
  where idx>1);

- gen-y-s January 29, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

delete from employee a
     where a.rowid > ANY(select b.rowid
                                          from employee b
                                          where a.empid = b.empid)

- Anonymous February 26, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

you can use this:

select * from Employee group by Emp_id,Emp_name,Emp_email;

- aditi November 10, 2013 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

delete from Employee 
where rowid not in (
select min(rowid) from Employee group by Emp_id
)

- vijay.edella May 01, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

How does a query delete something?

- Interested August 02, 2014 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

how about select distinct * from from Employee

- Anonymous April 01, 2015 | Flag Reply
Comment hidden because of low score. Click to expand.
0
of 0 vote

how about select distinct * from Empolyee

- qlu02@nyit.edu April 01, 2015 | Flag Reply


Add a Comment
Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

Learn More

Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.

Learn More

Resume Review

Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.

Learn More

Mock Interviews

Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.

Learn More