[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Define DB2 schema in data-source.xml ?

2005-12-19 Thread stscit04
Hi, is there a way to set the db2 schema to use in the datasource definition? something like myds url com.ibm.db2.jcc.DB2Driver myschema user pass Thanks in advance, Stefan View the original post : http://www.jboss.com/index.html?module=

[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - JBoss 3.2.6 + DB2 8.1 TIMESTAMP finder

2005-11-16 Thread stscit04
Hi, I have the following finder @ejb.finder signature="java.util.Collection * findByOpenAndOlderThan(java.util.Date d)" query="SELECT * OBJECT(tx) FROM Transaction AS tx WHERE tx.merchantTimestamp < ?1 * AND tx.sc=0 AND tx.bankTimestamp

[JBoss-user] [Persistence & CMP/JBoss] - Re: Can any one help me in writing CMP2.0 application

2004-12-29 Thread stscit04
Check out Xdoclet for generation of jboss-specific deployment descriptors. Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3860099#3860099 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3860099 --

[JBoss-user] [Persistence & CMP/JBoss] - CMR bean.addRelation(relatedBean) failes

2004-12-22 Thread stscit04
Hi, I am using Jboss 3.2.6 with the SLQ92 Compiler and have the following problem: I have 3 CMP entity beans (A1,A2 and B) both A beans hava a 1-1 relationship to B (A1 1---1 B 1 --- 1 A2). I can create a new instance of A1 and call b.set(a1), however the exact same call failes if I create a ne

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-22 Thread stscit04
Arne, you should really make yourself familiar with the documentation of Jboss, it will help you understand how ejb-selects are _different_ from ejb-finder methods. They ARE used to retrieve only a single field of an entity bean. You also should take the time and read the chapter about load-sets

[JBoss-user] [Persistence & CMP/JBoss] - Re: Adding CMR fails

2004-12-21 Thread stscit04
I have a similar problem. I have 3 Beans A1,A2 and B. both A1 and A2 have a 1-1 relationship to B. B has a 1-1 Relationship to both A1 and A2. If I create a instance of B and call b-setA1(A1), everything works, whereas b.setA2(A2) doesnt work. The Relationships are defined identical. I get the fol

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-21 Thread stscit04
Well, just forget the WHERE clause and you will get the names of all customers. Anohter possibillity is to define load-sets that correspond with the Xdoclet-defined value-objects. (You can define more than one VO for an EB). Regards, Stefan View the original post : http://www.jboss.org/index.ht

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB QL: Selecting anything different than entity beans

2004-12-21 Thread stscit04
What you migth want are EJB-Selects, they allow you to do something like SELECT c.name FROM Customer AS c WHERE c.id=?1 EJB-Selects are descibed in the JBoss dokumentation and are supported by special XDoclet-Tags. Regards, Stefan View the original post : http://www.jboss.org/index.html?modu

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-21 Thread stscit04
Hi, thanks for your help, it works! Is the SQL92 Compiler scheduled to become the default compiler for the JBoss 3.x series? Regards Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3859436#3859436 Reply to the post : http://www.jboss.org/index.html?m

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-20 Thread stscit04
I tried 3.2.6 and the Exception disappeared. But the query still gives incorrect results (or at least unexpected results, maybe I am thinking in the wrong way) The SQL executed under 3.2.6 is: SELECT DISTINCT t0_m.id FROM Merchant t0_m, MerchantPartnerContract t1_m_merchantPartnerContract WHERE

[JBoss-user] [Persistence & CMP/JBoss] - Re: EJB Select not working

2004-12-16 Thread stscit04
I set logging to debug and the generated SQL is Executing SQL: SELECT DISTINCT t0_m.id FROM Merchant t0_m WHERE (t1_m_merchantPartnerContract.id IS NULL) which doesn't look ok to me... Regards Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3858915#3

[JBoss-user] [Persistence & CMP/JBoss] - EJB Select not working

2004-12-16 Thread stscit04
Hi, I have 2 CMP Beans that have a 1-1 relationship Merchant and MerchantPartnerContract. I need to find all Merchants that dont have a contract, and to get their Ids. I trie to do this using the ejb-select SELECT m.id FROM Merchant AS m WHERE m.merchantPartnerContract IS NULL JBoss deploys it,

[JBoss-user] [EJB/JBoss] - Re: Unable to access remote entity bean. plz suggest

2004-07-09 Thread stscit04
If I understand your setup correctly, you are using the enity-beans remote interface, this is usually not a good application design. Instead, you should use a session bean in the same container as a facade to the enity bean. This is just a general suggestion, witout any cde I am not shure if I u

[JBoss-user] [EJB/JBoss] - Re: Unable to access remote entity bean. plz suggest

2004-07-09 Thread stscit04
Please post the method of the session bean that retrieves the entity bean data and returns it to the client. Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3841477#3841477 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode

[JBoss-user] [EJB/JBoss] - Package EJB interfaces in client-application/web-module ?

2004-07-09 Thread stscit04
Hi, I have an EJB Module running in Jboss and 2 Client-Apps, one running stand-alone, one running as web-module in an tomcat instance. Do I need to package the EJB interfaces (home/remote) into the client-apps or do I need them only at compile-time ? For now, I am packaging them into the client-

[JBoss-user] [Persistence & CMP/JBoss] - Re: ejb-select traversing CMR collections

2004-06-21 Thread stscit04
Thanks for your reply. Your code didnt work, but it tipped me off into the right direction. The working statement is: select c.id from A a, in (a.bs) b, in (b.cs) c WHERE a.id = ?1 Regards, Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3839379#383937

[JBoss-user] [Persistence & CMP/JBoss] - ejb-select traversing CMR collections

2004-06-18 Thread stscit04
Hi, in my App I have 3 CMP Beans with one to many relations. A 1 --- * B 1 --- * C (A has multiple B which has multiple C) I need to get all ids of C for an instance of A. I tried SELECT c.id FROM A , IN (a.bs.cs) AS c WHERE a.id = ?1) but it wont work. Is there a way to do this in a single qu

[JBoss-user] [Messaging, JMS & JBossMQ] - One more thing

2004-05-25 Thread stscit04
There is one more thing: Though I have set MyPoolSize to 100, it looks like there is only one MDB Instance working at a time (I did a log.debug(this,this,messageDrivenContext) and in the log I get the same pointers on every call for about 10 calls, the another one for the next 10 calls and so on.

[JBoss-user] [Messaging, JMS & JBossMQ] - poor MDB performance

2004-05-25 Thread stscit04
Hi, I am using Jboss 3.2.3 with mysql as persistent store for JMS messages. I have a large number of messages (about 20k) in the store. The performance is not very good, my MDB gets a new message every 500ms or so. The processing in the MDB itself takes about 100ms. Is there any way to find out

[JBoss-user] [Persistence & CMP/JBoss] - Re: JBoss transaction deadlock

2004-05-07 Thread stscit04
Hi, when does the lock ocour ? on ejbFind or on the first invokation of an beans getXX / setXXX method ? Stefan View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3834120#3834120 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=repl

[JBoss-user] [Persistence & CMP/JBoss] - Re: Updating entity bean fields using BeanUtils

2004-05-06 Thread stscit04
Hi, if you are using XDoclet, take a look at the @ejb.value-object tag. The handling of VOs is described on: http://xdoclet.sourceforge.net/valueobjects.html If you have any questions on this, dont hesitate to post in this thread Stefan View the original post : http://www.jboss.org/index.h

[JBoss-user] [Persistence & CMP/JBoss] - Executed SQL on findAll()

2004-04-16 Thread stscit04
Hi, I have an findAll() query in my entityBean. I select large numbers of beans with this method (up to 30k). The bean has an compound PK (id (String) + date (Date)). The server.log shows the following query: Executing SQL: SELECT blz, changeDate, flagDeletion, bankId FROM ShadowBLZ WHERE (blz

[JBoss-user] [Persistence & CMP/JBoss] - jbossQL in ejbSelect ?

2004-03-08 Thread stscit04
Hi, is it possible to use JBossQL (we need the COUNT function) in an ejbSelect method ? I found the jboss.query Xdoclet-tag, but it seems only to work with ejbFindBy methods. Thanks in advance Stefan http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3824691#3824691";>View the original

[JBoss-user] [Persistence & CMP/JBoss] - Re: ejb finder

2004-03-05 Thread stscit04
You have to specify the FULL qualified Name of the Classes. use java.lang.String instead of String. Regards Stefan http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3824449#3824449";>View the original post http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3824449>Reply

[JBoss-user] [Persistence & CMP/JBoss] - ejbSelect locking behaviour

2004-03-05 Thread stscit04
hi, What is the expected locking behaviour of ejbSelect methods ? eg I have a bean called Merchant, if I use an ejbSelectAllMerchantIds method via an ejbHomeGetAllMerchantIds, would this lock all merchant EntityBeans as findAll() would do ? Thanks in advance, Stefan http://www.jboss.org/index.

[JBoss-user] [Installation & Configuration] - Stop application on shutdown

2004-02-25 Thread stscit04
Hi, in this thread: http://jboss.org/index.html?module=bb&op=viewtopic&t=45890 someone asked about starting an application on startup. The answer was to use a servlets init-method and load-on-startup 1 . Is there a similar method that gets called on stopping/undeploying the application ?

[JBoss-user] JBoss MQ doesnt create tables on mySQL

2004-01-20 Thread stscit04
Hi, I configured Jboss to use MySQL to persist JMS messages. On startup, I get the following message: --- 12:39:29,515 ERROR [PersistenceManager] Starting failed org.jboss.mq.SpyJMSException: Could not resolve uncommited transactions. Messag e recovery may not

Re: [JBoss-user] JMS redelivery - how many times ?

2004-01-13 Thread stscit04
Adrian, again, you saved me a lot of time by sending a single line of text :-) Thank you so much ! It is really people like you who make Jboss a better choice than other app-servers (among other things). Regards, Stefan > http://sourceforge.net/tracker/index.php?func=detail&aid=744455&group_id=

[JBoss-user] JMS redelivery - how many times ?

2004-01-13 Thread stscit04
Hi, is there a possibility to tell Jboss to redeliver a message N times to a MDB ? Something like: message.setProperty(JBOSS_JMS_REDELIVERY_COUNT,) ? Thanks in advance Stefan --- This SF.net email is sponsored by: Perforce Software. Perforce

[JBoss-user] session bean lookup and create - where ?

2004-01-12 Thread stscit04
Hi, I am currently working on a application which consists of several sessionBeans (stateless). The session beans are using each other through their local-interfaces. Bean A is using bean B. I am using he xdoclet generated util-classes to lokkup the local-interfaces. The util-classes cache the h

RE: [JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
Thank you very much, problem solved !! Thanks again, Stefan > Well your MDB does not run in a transaction context. Here is an example of > Xdoclet tags that enable JTA transactions in an MDB: > > /** > * ... other xdoclet stuff here > * > * @jboss.destination-jndi-name name="queue/parcelInstr

RE: [JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
> Aaaarggg Sorry ;-) > >>As I understand it, the only way to force re-delivery of the JMS message >>is to throw an EJBException to force JBoss to rollback >>the transaction. > > No. You cannot throw an EJBException from onMessage, see the spec. If you > want to rollback the message, use messageDriv

[JBoss-user] MDB JMS redelivery

2004-01-09 Thread stscit04
Hi, I have a MDB which takes messages from a Queue. In the onMessage() method, I am working with CMP beans. If something goes wrong, I want the JMS message to be redelivered, but the changes on the CMP beans should not be rolled back. As I understand it, the only way to force re-delivery of the J

[JBoss-user] Tell Jboss to create INNODB tables (was: Session/Entity Bean Transaction Rollback)

2003-12-23 Thread stscit04
Adrian, thanks for the link, this was exactly what I needed. Sometimes you dont need many words to explain something :-) One more question: Where can I tell Jboss to create tables with TYPE=INNODB ? btw: I bought the JBoss dokumentation, but this mailing list is far more helpfull for Jboss users

Re: [JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Thank you very much, but this didnt solve my problem. I am looking arround at the net, and it seems like a lot of peoploe have the same problem - no answers I guess it has to do somthing with my mySQL db. Does anybody know how to configure a mysql as XA Datasource in JBoss ? Thanks again, any

Re: [JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Hi, I forgot something, I am not shure if this is important: Im am using mySQL as RDBMS. The Datasource is configured as follows: mySQL_partnerMgmt jdbc:mysql://localhost/partnerMgmt org.gjt.mm.mysql.Driver root > Hi, > > I have a sessionbean (stateless), that provi

[JBoss-user] Session/Entity Bean Transaction Rollback

2003-12-22 Thread stscit04
Hi, I have a sessionbean (stateless), that provides a method to create some entitys. If the creation of one Entity fails, I want do rollback all creations, there should be one or all entitys in the DB. I tried to set transaction type="required" on the method and I throw EJB Exceptions if something

Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04
>> I have seen the UUIDKeyGeneratorFactory, where can I find information >> about how to write my own factory ? > > You need to implement two interfaces: > org.jboss.ejb.plugins.keygenerator.KeyGeneratorFactory and > org.jboss.ejb.plugins.keygenerator.KeyGenerator. > Check the org.jboss.ejb.plugins

Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04
>> I have seen the UUIDKeyGeneratorFactory, where can I find information >> about how to write my own factory ? > > You need to implement two interfaces: > org.jboss.ejb.plugins.keygenerator.KeyGeneratorFactory and > org.jboss.ejb.plugins.keygenerator.KeyGenerator. > Check the org.jboss.ejb.plugin

Re: [JBoss-user] automatic primary key generation for CMP entityBeans?

2003-12-12 Thread stscit04
I have seen the UUIDKeyGeneratorFactory, where can I find information about how to write my own factory ? I also need to know how to use entity-commands/how to use the default keygenerator. Thanks in advance, Stefan > select max() is not safe. Look at standardjbosscmp-jdbc.xml file for > entity-

[JBoss-user] automatic primary key generation for CMP entityBeans ?

2003-12-11 Thread stscit04
Hello, everyone I have a Entity Bean with a String as PK. The String consists of the characters [0-9]and[A-Z]. My approach is to get the latest key from the DB with an ejbSelect method(select MAX()). Is this safe, or is it possible that I assign accidentially the same PK to 2 entitys because

RE: [JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
You are right, I just doesn't look elegant to me :-) I was hoping for another more elegant solution, but I will probably go for the suggested one. Thanks, Stefan >> Unfourtunately, my app doesn't have >> an web-component, so I have to find some way to do this with > > Why don't you just add a si

[JBoss-user] Timer MBean cant handle notification dates in the past

2003-12-08 Thread stscit04
Hi, I am trying to use the Timer MBean to notify parts of my application. Sun tells me about the expected behaviour: If the timer notification to be inserted has a date that is before the current date, the method behaves as if the specified date were the current date. The first notification is d

RE: [JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
First of all: Thank you ! Unfourtunately, my app doesn't have an web-component, so I have to find some way to do this with ejbs. I thought of doing this in the ejbCreate method, but this method doesn't get call until the first client connects > If your app has a web component to it you can us

[JBoss-user] performing tasks on application startup

2003-12-08 Thread stscit04
Hi, Is there a elegant way to perform tasks in an application after the application is deployed an started. I think of tasks such as registering objects for timer notifications Thanks in advance Stefan --- This SF.net email is sponsored b

[JBoss-user] JMS scheduled redelivery

2003-12-04 Thread stscit04
Hi, I am using Jboss 3.2.2 and a MDB as JMS destination. The MDB should take a message from the queue, process it and sometimes (if processing fails) put it back into the queue. Is it possible to tell JMS that I want to receive the message from the queue again after a period of time? Otherwise I