This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Soft Skills and have John Sonmez on-line!
See this thread for details.
The moose likes JDBC and the fly likes Union of mysql statement Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Union of mysql statement" Watch "Union of mysql statement" New topic
Author

Union of mysql statement

malik ge
Ranch Hand

Joined: May 13, 2011
Posts: 69
Hi,

Is it possible to get the result of two sql statements by using keyword "Union" in Java like this...

If yes, can you tell me how to do that.


Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 31057
    
232

Yes. Except for the missing space before and after the "union" keyword, it looks right. What error do you get?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
 
subject: Union of mysql statement