*
The moose likes EJB and other Java EE Technologies and the fly likes Turning the Query debug on Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Turning the Query debug on" Watch "Turning the Query debug on" New topic
Author

Turning the Query debug on

Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9345
    
    2

Guys,

How can I see what query is being executed in the server...I mean the EJB QL? I remember in Hibernate, we specify this in the xml config file. Is there anthing similiar to that I can do in EJB?
[ October 01, 2008: Message edited by: Jothi Shankar Kumar Sankararaj ]

SCJP 1.4, SCWCD 1.4 - Hints for you, Certified Scrum Master
Did a rm -R / to find out that I lost my entire Linux installation!
Vinod K Singh
Ranch Hand

Joined: Sep 30, 2008
Posts: 198
See if your connection pooling library provides SQL logging or not. If yes, then turn that on.


My Blog
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 9930
    
159

Originally posted by Jothi Shankar Kumar Sankararaj:
Is there anthing similiar to that I can do in EJB?



EJB3 or EJB2.x? I think in EJB3 you can pass the property through your persistence.xml.


[My Blog] [JavaRanch Journal]
Joe Harry
Ranch Hand

Joined: Sep 26, 2006
Posts: 9345
    
    2

Originally posted by Jaikiran Pai:


EJB3 or EJB2.x? I think in EJB3 you can pass the property through your persistence.xml.


I'm refering to EJB 2.x
 
Consider Paul's rocket mass heater.
 
subject: Turning the Query debug on
 
Similar Threads
EJB QL: Select TOP 10
With EJB-QL, can I use ORDER BY clause?
Flush Entity EJB update to DB.
Subquery in CMP 2.0
Entity Bean Problem