File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Nested Queries with comparison operators

 
Arvind Rao
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Everybody,

I have a question about nested queries combined with Comparison operators.
Is is possible to have a query like this.

The scenario is i have two tables employee and dependent where employee has empname empid and so on. Dependent has empno deptno dependentname and so on.

QUERY



MySQL is currently down in my office system and hence i cannot check it out myself.

Thanks a lot in advance and regards,

Arvind Rao

s
 
Hebert Coelho
Ranch Hand
Posts: 754
Eclipse IDE Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there any error when you run it?

By the way, select count(empid from dependent where xyz="abc") is missing a ) after the empid.

select count(empid) from dependent where xyz="abc")
 
Arvind Rao
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Thanks for replying..
Wrt to executing the query my MySQL server is down for the day.
And wrt to the bracket it was just a typo. Sorry about that.

Is the query structurally correct is my question. Can such queries be done?
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic