EJ3 Problem. LEFT JOIN doesn磘 work with ManyToMany relations

1180 byte By haykena at 2007-11-27 4:31:52
I have two entities, Project and Tool that they have a many to many relation. I execute this sql query and I don`t get any result:List<Project> resul = em.createQuery("SELECT p FROM Project p LEFT JOIN p.tools t").getResultList();In the database there is one row in Project table that ...

Detect Container

215 byte By Yazana at 2007-11-27 4:32:04
I have developed a library that can be used from web (servlet) applications or desktop application, I'm wondering if their is a way to dynamically detect if the library is called in desktop or web container.

Bean to avoid concurrent access

559 byte By archnavisha at 2007-11-27 4:32:09
Hi,The scenario is as follows:1. There are two methods by which a common record can be accessed2. However, when one method has access to this common record, the other method should not have access to it.I am using a stateless session bean, with Transaction Type set to container. I believe i am ...

How to send an Html File as an Attachment tht has style included?

83 byte By pra_n_dea at 2007-11-27 4:32:14
Hi Friends,If anybody has sample code ...please post it here..

local Referance tag in Sun one server

365 byte By riteshkumara at 2007-11-27 4:32:32
Hi All, In my ejb-jar.xml file have one ejb in that i have local Ejb. How i can spacify in the sun-ejb-jar.xml.when i trying to lookup the local ejb i got name not found exception .where as jboss we have one tag i.e. <local-jndi-name>like wise we have any tag for refer the local ejb in ...

Using XPATH returns NULL.Please see and advise

1069 byte By bhuru_luthriaa at 2007-11-27 4:32:42
Hi,Why is my xpath giving null for the the flwg ...

Authenticates but throws AuthenticationFailedException?!?!?

3568 byte By Gabriel.Galvaoa at 2007-11-27 4:32:59
I have got the following code used for sending a simple mail over a SMTP with Authentication connection.boolean debug = true;// Create a mail sessionjava.util.Properties props = new java.util.Properties();props.put("mail.smtp.host", smtpHost);props.put("mail.smtp.port", ...

failed:javax.naming.NameNotFoundException: QueueConnectionFactory

3857 byte By CJ_125a at 2007-11-27 4:33:29
hi allI have the problem how to solve this problem? when i was lookup through jndiname it was error but i declared it in a descriptor. Error : init:deps-jar:compile-single:run-single:Jndi lookup failed:javax.naming.NameNotFoundException: QueueConnectionFactory not foundJava Result: 1BUILD ...

nullpointerexception when accessing local EJB3.0 method

1071 byte By sammaesa at 2007-11-27 4:33:39
Hi all,I'm trying to replace some of the business logic in an existing struts application by EJB3.0. I first made the simplest stateful sessionbean and try to call it via a local interface. When doing this I always get a nullpointerexception when the "sess.hello()" is called.What am I doing ...

Bug in XSLT SE?

4904 byte By corstijanka at 2007-11-27 4:34:07
I think I found a potential bug in the XSLT SE, but Im not sure *if* its a bug, and *where* to report it. (OpenESB / OpenJBI components?)I am trying to use the XSLT SE, in combination with the HTTP BC to create a filter for several operations spread over various services (a canonical schema ...

jars on classpath within webservice?

8260 byte By dudleydawsona at 2007-11-27 4:35:00
Hi. I've created a web service using apache axis. I am having a problem getting my external classes on the classpath of my web service.import com.mycompany.MyClasspublic class MyService{ static {MyClass.initialize(); } public String myServiceMethod(){...... }}When i deploy on weblogic 9.2 i ...

JAX-WS Web Service with XFire Client

9453 byte By benobia at 2007-11-27 4:35:43
I wrote a simple web service and client using XFire. However the server now needs to be JAX-WS. I wrote a simple service using NetBeans but I can't seem to get it to work with XFire. JAX-WS doesn't seem to like the SOAP XFire is sending it and the parameters passed into the web method are ...

xml sax parser

292 byte By Dolphya at 2007-11-27 4:36:17
Hi all,I am newbie to xml. I am using SAX parser for parsing xml documents. I have to write a code which parses all types of xsd files(including which can contain inline , referenced or both). Can anyone help / guide me how to code a generic xsd parser?Thanks in advance,

Unable to invoke local interfaces in EJB 2, SJSAS 9 environment

3516 byte By Jithesh_Gangadharana at 2007-11-27 4:37:10
Hi,I am unable to get SJSAS to register local interfaces for an BMP entity bean. I am new to entity beans, and am trying out a simple case using EJB 2.0 deployed on SJSAS 9. I even had tried setting source level to 1.4, but no luck.EJB looks ok, as it was verified successfully by netbeans 5. ...

Java Source Level for Web Services

580 byte By Ajaxranda at 2007-11-27 4:37:35
I tried to create a simple web service using Netbeans 5.5. but its giving this error message under New Web Services Wizard. and I can't continue.To Create Web Services in this project, java source level must be at least JDK 1.5.What is the meaning of this Error. And what should i do to prevent ...

where do we use Session Beans in Insurance projects

155 byte By sowbharia at 2007-11-27 4:37:50
hiin case of Session Beans ,where do we use Session Beans in Insurance proects and how d we use themplz give me replybye

Which is the BEST Java Web Service Framework to use?

532 byte By dhillaruna at 2007-11-27 4:38:01
Hi all,I'm a beginner to Web Services.I am planning to implement java web services to make the communication between java(Tomcat Server) and C# client.I found list of web service frameworks like,1. Apache Axis,(POJO,Axiom)2. JSON-RPC,3. Java Web Services Development Pack ,4. Web Services ...

how to edit content on server

325 byte By chaithubtecha at 2007-11-27 4:38:13
hello guys i have a static webiste in which and admin will be there to edit the content of the website.for editing the website he need a html editor in javathrough which he shold open the static page to make changes.is there any tools available like that.plz help methanks in ...

how to get fixed results using JPA

377 byte By vpalkondaa at 2007-11-27 4:38:58
Hi I have a table with lot of rows, when I querry, it is taking a lot of time and I am displaying that many rows in UI in single table. So it is not scaling well.SO I am planing to show x number of row in on page. So for that to achieve, how do I querry the db (derby) using JPA to get first 25 ...

replacing & in a string <xsl:if>

394 byte By srins_2000a at 2007-11-27 4:39:18
Hi,I'm a newbee to xsl. I have to do the following in my .xsl file.<xsl:if test="statement_type = 'Myself & bod went to a movie'"><call template></xsl:if>The problem is in this xsl:if the char '&' is considered as a conditional statement. But its part of the ...

even from sample database in netbeans i can not create a entity

5567 byte By serkolaa at 2007-11-27 4:40:32
Hieach time with each database when i create entity bean from database with netbeans 5.5 i become this message and i can not read the data from database! (see please the server log ): Got SQLException executing statement "CREATE TABLE ......I am confused because:1-i can create the entity ...

I am looking for resources to write JUnit tests on EJB 3.0 classes?

262 byte By jtp512a at 2007-11-27 4:41:24
Java EEEJB 3.0I am looking for resources, tutorials or examples on writing JUnit test for EJB 3.0 classes?I've been googling this subject and have found sparse information, so any help would be appreciated.Thanks,--Todd

webservice with soap attachment

202 byte By roms_techya at 2007-11-27 4:41:36
Hi everybody!I want to send an XML file as an attachment to the webservice using IBM RAD.Can anyone help me doing this possibly with some code snippets?I would appreciate your help.

quick beginner's question

2454 byte By pnandrusa at 2007-11-27 4:42:26
(this is cross-posted, i think this forum is more appropriate than the 'javabeans' forum i originally posted in)i was reading this from an O'Reilly book. What do the @ symbols mean? I didn't see a clear explanation of that...import javax.persistence.* ;@Entity@Table(name="CABIN")public ...

Exposing a WS through OpenESB

840 byte By bbarkera at 2007-11-27 4:42:37
I am trying to take an external web service and expose it through OpenESB. Would it be correct to say that that would make the external service accessible to service consumers using other protocols assuming that I have a BC for that protocol?I have looked at the examples and everything I read ...

xpath expression don't work

2352 byte By Taigoa at 2007-11-27 4:42:39
i need to select two "sect" by idtry {// parse the XML as a W3C DocumentDocumentBuilder builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();Document doc = builder.parse(new File("book1.xml"));XPath xpath = XPathFactory.newInstance().newXPath();String expression = ...

Integrating custom binding component

945 byte By adwagsa at 2007-11-27 4:42:46
The answer to the question may be obvious, but here goes.I have developed a custom binding component (integrates a legacy system with it's own proprietary binary wire protocol and session management). I'm using OpenESB 2.0 and have followed the provided samples. I can install my BC and it ...

Error when deploying as ear, ok when deploying as war, why?

543 byte By Dani_drioa at 2007-11-27 4:43:06
Hello all,I have a strange problem with a JSF project that uses myfaces and shale. I'm using Netbeans 5.5, and all works fine when the web application is deployed independently as a war, but when deploy the full ear i have the following error:java.lang.NullPointerExceptionat ...

Can't find handle to response message in a Web Service

778 byte By joeysr20deta at 2007-11-27 4:43:30
I've created a bunch of SOAP services in netbeans that expose parts of a file application that I've written. I have a service that reads in a file as a SOAP attachment from a client. Basically an Upload service.Now I am trying to create a service that sends a file as a SOAP attachment back to ...

Browser history need to be refreshed

505 byte By Jagannathana at 2007-11-27 4:44:13
Hi All,i am working in a CMS, i want to refresh browser history, when i click the browser back button.ideally when we click browser back button, whatever the page which is available in history will be displayed without the page refresh. but here i need to be refresh the browser history. i have ...

Using XSD to remove elements in a XML object?

458 byte By JWKC-5ivea at 2007-11-27 4:44:15
please anyone if u know what i can use to do this, reply to this...i have an XML file which contains, e.g. 10 elements, and a XSD file which expects only a subset of this XML file, e.g. 5 elements from this XML file. The document structure of this XML and the XSD file are the same.i want to ...

Parsing XML and storing values in HashMap

3804 byte By Selvan_RCa at 2007-11-27 4:44:39
Hai I am parsing this XML file using SAX parser .I am getting the output. But how to store the ta and value in HaspMap as key /value pair.Can anyone help me please.Thanks a lot,selvan*****************CrsCreate.xml*****************<?xml version="1.0" encoding="UTF-8"?><!-- $Id: ...

Not able to send mail to gmail or yahoomail

335 byte By Manojmaruthoora at 2007-11-27 4:44:58
mailing is possible within the intranet server but while sending mail to gmail or yahoomail it is throwing the exception"javax.mail.MessagingException: Could not connect to SMTP host: gma25; nested exception is:java.net.ConnectException: Connection timed out: connect"what to dopls ...

Please recommend a good JEE tutorial.

172 byte By dislimita at 2007-11-27 4:45:03
Please recommend a good JEE tutorial.A friend asks me to recommend a good JEE tutorial. He also hope that it can be used as a reference book later. Any ideas?

Removing ParentNode in a xml document

1082 byte By srins_2000a at 2007-11-27 4:45:24
Hi All,I have a XML document as below :<First> <Second><Third><Third_x>Some text</Third_x><Third_y>Some text</Third_y><Third_z>Some text</Third_z><ab>Some ...

How to get files for attachment coming from request

314 byte By Ashish.Mishra16a at 2007-11-27 4:45:48
Hi Friends,'I am working on attachments. Now how to get those files from a file upload form of html. I m getting some files form Adobe Flex GUI using FileReference.Now i want to attach these files in my message & send it to server. How can i do so.Thanks in advance for your ...

Got a Problem with attachment, PLEASE HELP!!!!

975 byte By Jhay_area at 2007-11-27 4:45:59
here is my code,File newFile = new File("C:\\107.jpg");MimeBodyPart mbp2 = new MimeBodyPart();DataSource source = new FileDataSource(newFile);System.out.println(source.toString());DataHandler dh = new DataHandler(source);mbp2.setDataHandler(dh);<<-- im having a problem here, my program ...

Javamail delete mail in READ_ONLY mode

2256 byte By NullpointerForevera at 2007-11-27 4:46:00
Hello,I want to fetch my GMail mails without deleting. My example code fetch e-mails, but the mail is delete from GMail account. I observe, that the line where is message[i].getContent() delete mail. If I remove this, the message is still alive. Thanks for any help.String SSL_FACTORY = ...

Problem with Remote EJB 3.0

1558 byte By GonzaloFerreyraa at 2007-11-27 4:47:25
Hello all, I'm having a problem when i try to lookup the remote interface of a EJB3.0.I wrote a EJB with a remote interface and a local interface.When accessed locally all works fine but when i tried to write a stand-alone test program to access the remote interface every time i'm getting the ...

How to provide streaming in J2EE web application?

367 byte By vikaskhengarea at 2007-11-27 4:47:59
Hi Friends,I want to build web application which will provide streaming of data. This data may be in raw data, binary, files, audio, video etc. As we are using HTTP protocol for web application, then how to do streaming between server and client using HTTP protocol i.e in request response ...

Document Style webservice : Operation Identification problem..

1660 byte By Rajasekaran_sun_forum_screena at 2007-11-27 4:48:05
I've a problem with webservice, I use document-literal-unwrapped style webservice and I've cnlosed my WSDL and SOAPEnvelope herewith.Here's a snippet of my Soap Message..--<soap:Envelope xmlns:soap=" http://schemas.xmlsoap.org/soap/envelope/"><soap:Body ><rsq:RSDocument ...

EJB 2 Delete directly in SQL.

608 byte By mrbluea at 2007-11-27 4:48:20
Hi alli got a quick question for you all.Im currently updating a system in written in EJB 2 and need to delete a LARGE number of records in one go (10s possibly 100s of thousands of records at a time).I feel that doing this by finding the beans using the remove method on each bean returned is ...

Java mail on mac os

479 byte By lildavesflavaa at 2007-11-27 4:49:18
I am new with Java mailI research throug internet and i end up downloading javamail 1.4in the read me file there some directions to install javamail package on window, linux and unix.does it mean since i have a mac i can not install it?if i can how?am using eclipse 3.2 and jvm 1.5 mac os i try ...

How to map an object to its ID in a table?

321 byte By vwuvancouvera at 2007-11-27 4:49:25
Here is my situation:class Foo { private Bar bar;}How to map the Bar object into a DB table column of its ID on the ORM mapping file?Thanks very much in ...

reading MimeMessages from file problem

2658 byte By LukasCa at 2007-11-27 4:49:37
Hi,I have a problem with reading MimeMessages from file.This method save all MimeMessages into file:public void saveToFile(){Vector<MimeMessage> file= new Vector();if (!file.isEmpty())soubor.removeAllElements();for (int i = 0; i < messages.length; i++) {file.addElement(messages[i]); } ...

with POP3 protocol, How Outlook access all the folders

458 byte By Ashish.Mishra16a at 2007-11-27 4:51:15
Hi friends,I have some doubts. Our mail server doesn't support the IMAP protocol. When i access the mails using Outlook, then I m able to get all the messages of INBOX as well as Trash & Deleted Messages?How it happens, When only INBOX is accessible to user Using POP3 protocol. Using ...

Netbeans give me J2EE 1.4

234 byte By BomberMana at 2007-11-27 4:51:42
Hi,I'm confusing with netbeans.I have installed JavaEE5 and then install netbeanwhen i create web project it give me 2 choice J2EE1.3 AND J2EE1.4why it did not show JavaEE5?Thanks for advance

Creating CMR

326 byte By sirynxa at 2007-11-27 4:51:49
I'm trying to create CMR with JBoss and MySQL but I cannot make the relations appear in the database. I'd like something to explain from the begining how to create this kind of relations. I'm a beginner and I'm doing a J2EE application that needs some relations in the db.I'm using JBoss, ...

JDOM and Enviroment Variables

1148 byte By ShakuR_a at 2007-11-27 4:53:10
Hello everybody,I have successfully installed Jdom-1.0. I have also created the following batch file after following the instructions of a tutorial for setting up classpath variables.@echo offREM File setcp.batset JDOM_HOME=C:\Program Files\Java\jdom-1.0\jdom-1.0\set ...

Getting error 421

630 byte By NareshIndiaa at 2007-11-27 4:53:34
Hi All,I am using a code sample for sending mail using javamail. It works fine if i call the class from a jsp page. But i have called the class using TimerTask (schedule to run once every day at midnight). The class TimerTask calls 2 different class for sending different types of mails ...