Many to One Mapping issue
Hi Experts,
I am currently facing issue with many to one mapping . I have a source schema called revenue having Profit and Profit GST which is looping multiple times. I need to copy the name,value and GST value for each type into the destination schema.
i am using Looping funtiod to create item profit records and than copying name and value from source to destination but the problem statement is that i am unable to map the GST value
Thanks
Abhishek
could you post the schema definition please
well why i am asking is, in General matching the records will be based on common node values in corresponding records.
Assume you have 2 records of Profit and 2 records of ProfitGST in the source message like below, you cannot match the records unless you have some value common in both the records. i mean there should be some common node or attribute value that exits in
both records.
assume the following sample with 2 records each
<ns0:Revenue xmlns:ns0="http://TestSample">
<ns0:profit availabilityIncentivePayment="342" increasedCapacityCharge ="121" increasedCapacaityPayment="231" />
<ns0:profit availabilityIncentivePayment="100" increasedCapacityCharge ="110" increasedCapacaityPayment="120" />
<ns0:profitGST availabilityIncentivePayment="55" increasedCapacityCharge ="21" increasedCapacaityPayment="23"/>
<ns0:profitGST availabilityIncentivePayment="150" increasedCapacityCharge ="160" increasedCapacaityPayment="170"/>
</ns0:Revenue>
if you observe the above sample instance, it does have 2 records each, but Profit record's nodes values
are no where common with ProftGST record's node values.
And for every Profit record, you want to pick corresponding GST value from ProfitGST record. However, since you don't have atleast one common node/attribute value here, you will not find a way to relate corresponding records. Means while mapping the first
record of Profit, it cannot decide which record's nodes values in the ProftGST should pick to match as there are 2 records of ProfitGSt and with no relation with Profit Records.
if the requirement is such that the records should be matched by the order(index) irrespective
or the values in them, then that can be achieved easily with postion() function in the for loop. just try to use code some thing like below sample xslt script like below, apply the proper name spaces and put full names as applicable in your scirpt, mould
it as per your need
<ns0:Root>
<xsl:for-each select="Profit">
<Profit>
<xsl:if test="@availabilityIncentivePayment">
<name>
name>availabilityIncentivePayment</name>
</name>
</xsl:if>
<xsl:if test="@increasedCapacityCharge">
<Value>
<xsl:value-of select="@increasedCapacityCharge" />
</Value>
</xsl:if>
<xsl:if test="../profitGST/@availabilityIncentivePayment">
<ProfitGSt>
<xsl:value-of select="../profitGST/@availabilityIncentivePayment[position()]" />
</ProfitGSt>
</xsl:if>
</Profit>
</xsl:for-each>
</ns0:Root>
Please mark the post as answer if this answers your question. If this post is helpful, please vote as helpful by clicking the upward arrow mark next to my reply.
Similar Messages
-
One to one mapping issue - urgent
Dear all SAP Experts,
Client is requiring when we do Gate entry pass one to one mapping ie, 1 gr = 1 GRn.
Can you explain
regards,
ramanarI think, you want to sent a material outside & get back after some time.
In SAP there is no option for creating Gate Pass in standard.
But, try the below suggested procedure as a work around process;
Repair Process (Reconditioning) via Returnable Gate Pass: -
1. MM01 - Create Material Master for every Spare Part / Machinery to be sent to Vendor for Repair (Reconditioning) as Non-Valuated (Material Type "UNBW") (Do not extend Accounting and Costing views since you don't require postings of Stock value and consumption values, you only want to track the Service/Repair Charges)
It's not necessary to have materials as Non-Valuated always, it depends on your requirement.
2. MIGO - Goods Receipt > Others (Receive the quantities of these materials using Movement Type 501 / 511) - Only if Stock of Material is not available.
3. ME21N - Create Subcontracting PO (Here Main Material and Component will be same material)
4. MB1B - Transfer Posting w.r.t. Subcon PO (Mvmt Type - 541, Spare Part stock will get posted to Vendor Stock)
5. MB90 - Take Print out of this Material Doc as Returnable Gate Pass (U need to configure Message Determination of Inventory Mgmt)
6. MIGO - GR against Subcon PO (101 - Receive Spare Part, 543 O - Consumption of Spare Part form Vendor Stock)
7. MIRO - LIV for Service Charges w.r.t. Subcon PO
8. MIGO - Goods Issue > Others (Do GI of Subcontracted Material using Movement Type 502 or 512) -
Conversion Files - many to one mapping
Folks,
This is something that used to work fine in BPC MS but NW is giving me trouble with the data load. We've setup a custom BW cube as a source to our BPC consolidation application.
On a Consolidation App we don't need all ECC accounts and we simply consolidate many of them into a single consolidation account.
Let's say I have this source data from the custom cube:
Account1, $100
Account2, $200
Account3, $300
And this mapping table for the Account dimension:
Account1, ConsAccount1
Account2, ConsAccount1
Account3, ConsAccount1
I would expect BPC to load this final data into BPC Consolidation cube:
ConsAccount1, $600
But it isn't happening and marks a warning and nothing gets loaded in the cube.
This is very common in Planning / Consolidation apps and I won't expect users to maintain conversions using BW directly as it goes against all benefits BPC provides to Finance people.
Any way I can get out of this?
Thanks
PauloHi Paulo,
there are two ways to put data on BPC cube, either using IMPORT FROM INFOPROVIDER or UPLOADING a flatfile.
If you want to map many to one,you will need a conversion file.
EXTERNAL INTERNAL
ACCOUNT1 BPC_ACC
ACCOUNT2 BPC_ACC
Hope this helps. -
TopLink Version: 10.1.3.5.0.090715
JBOSS: 5.1.0
JDK: 1.6.0.17
Database: Microsoft Sql Server 2005
Problem Description: I have a table (TestTable1). This table has a PK that is a number from a sequence table as well as a 'SystemAssignedKey' that uses MS SQLServer Idenity generator. I can save this object by itself with no problem.
My java object for TestTable1 would look like:
Integer systemAssignedKey; --> MS Identity
Integer tableGeneratedID; -->generated through a key table
TestTable2 testTable2; -->object with foreignkey to the above values.
I have a second table that has 2 foreign keys to the table described above. When I save a new TestTable1 Object, I also want so save this object. Since I do not have the keys until the transactions commit I wanted to utilize the OneToOneMapping.
I used the example 3-10 in the following document:
http://download.oracle.com/docs/cd/B10464_01/web.904/b10313.pdf
When I attempt to save TestTable1 object 1 the fk in TestTable2 object 2 are all NULL at time of insert causing an error.
First I am curios is this possible with using the MS Identity Key. Secondly can you help identify if I have an issue with my mappings?
TestTable1:
//descripter and set up code left out...
OneToOneMapping testMap= new OneToOneMapping();
testMap.setAttributeName("TestTable2");
testMap.setReferenceClass(com.xxx.TestTable2.class);
testMap.useBatchReading();
testMap.setCascadeAll(true);
testMap.dontUseIndirection();
testMap.addTargetForeignKeyFieldName("TestTable2.ID1", "TestTable1.systemAssignedKey");
testMap.addTargetForeignKeyFieldName("TestTable2.ID2", "TestTable1.tableGeneratedID");
testMap.useJoining();
descriptor.addMapping(testMap);
In the TestTable2table I have the following. This is the table based on this mapping setup i would expect to have the values populated at time of commit based on this mapping:
OneToOneMapping testMap2= new OneToOneMapping();
testMap2.setAttributeName("TestTable1");
testMap2.setReferenceClass(com.rbs.common.etspii.impl.LESLegalEntityImpl.class);
testMap2.useBatchReading();
testMap2.setCascadeAll(true);
testMap2.dontUseIndirection();
testMap2.addForeignKeyFieldName("TestTable2.ID1", "TestTable1.systemAssignedKey");
testMap2.addForeignKeyFieldName("TestTable2.ID2", "TestTable1.tableGeneratedID");
testMap2.useJoining();
descriptor.addMapping(testMap2);
With this configuration TestTable1 would save with the correct values(the IDENTITY and Seq Number), however the TestTable2 object would insert NULL values. I would expect those to be populated with the values in the TestTable1.
Any help would be greatly appreciated!
thanks,
JeremyChris,
Thanks for the quick response.
Here is how i have the sequenceing set up for for of the ID's. The other, the Identity on MS Sql Server, is done at the table level.
public void applyLogin() {
DatabaseLogin login = new DatabaseLogin();
login.usePlatform(new SQLServerPlatform());
login.setDriverClassName("net.sourceforge.jtds.jdbc.Driver");
login.setUserName("toplink_user");
login.setEncryptedPassword("");
// Configuration properties.
login.setUsesNativeSequencing(false);
login.setSequencePreallocationSize(2000);
login.setSequenceTableName("LESKeyAssigner");
login.setSequenceNameFieldName("attributeName");
login.setSequenceCounterFieldName("nextNumber");
login.setShouldBindAllParameters(false);
login.setShouldCacheAllStatements(false);
login.setUsesByteArrayBinding(true);
login.setUsesStringBinding(false);
if (login.shouldUseByteArrayBinding()) { // Can only be used with
// binding.
login.setUsesStreamsForBinding(false);
login.setShouldForceFieldNamesToUpperCase(false);
login.setShouldOptimizeDataConversion(true);
login.setShouldTrimStrings(true);
login.setUsesBatchWriting(false);
if (login.shouldUseBatchWriting()) { // Can only be used with batch
// writing.
login.setUsesJDBCBatchWriting(true);
login.setUsesExternalConnectionPooling(false);
login.setUsesExternalTransactionController(false);
setLogin(login);
Sequencing for TestTable1
Descriptor descriptor = new Descriptor();
descriptor.setJavaClass(com.xxxl.TestTable1.class);
descriptor.addTableName("dbo.TestTable1");
descriptor.addPrimaryKeyFieldName("TestTable1.tableGeneratedID");
// Descriptor properties.
descriptor.useSoftCacheWeakIdentityMap();
descriptor.setIdentityMapSize(100);
descriptor.useRemoteSoftCacheWeakIdentityMap();
descriptor.setRemoteIdentityMapSize(100);
descriptor.setAlias("LESLegalEntity");
descriptor.setSequenceNumberFieldName("TestTable1.tableGeneratedID");
descriptor.setSequenceNumberName("legalEntityNumber");
So if you will notice i have 2 id's. One of which is done via sequence table the other via MS Identity column.
Now what i have done is get the assigned key from the table prior to the save. I have set this on the object. So this value is actually populated in TestTable1 object prior to the submit and commit. However when it is committed both ID's are NULL for TestTable2 object. This makes me think i have not set up the mapping correctly or I am not using as it is supposed to be.
Thanks for the pointer, I will make that change.
Jeremy -
Please help: Two-Sided One-to-One Mapping issues warning when owned instance does not exist
Hello,
Is it expected behavior? I have two classes A and B, B references A and its
foreign key column is its PK
A owns B (marked as inverse-owner in JDO metadata) when I access A.getB() if
B does not exist I get a warning.
Is it to be expected? Does two sided relation always require presence of
both sides of the relation and does nto fit my need?
Is there any way to have bi-directional association in my case with owned
record being optional?
Should I use two simple one sided one-to-one or may be simple one sided from
child to owner and One-to-One with Inverse Columns from owner to child
What are disadvantages of using two one sided (simple and inverse) vs.
two-sided?
Thank you
AlexHere is what I had to do to solve this issue:
Basically I had to add the MSSQL TCP/IP port as an end-point in Azure. After I did that, then I was able to create the data-source. However, I was only able to authenticate with a SQL account, as any domain account would return me an error saying that the
domain isn't trusted.
What puzzles me here is how come the Data Source Manager would inform me that an account username/password was invalid, but it would fail/timeout if I provided valid credentials (!?!?!!?) -
I have had TOPLINK-28018 error afte I had added one-to-many or many-to-one
Hello.
I am using TopLink and Spring. I have the followng persistence.xml:
<persistence xmlns="http://java.sun.com/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
version="1.0">
<persistence-unit name="registry" transaction-type="RESOURCE_LOCAL">
<mapping-file>ru/lanit/ps/registry/model/rpaymenttype.xml</mapping-file>
<mapping-file>ru/lanit/ps/registry/model/radministrativelevel.xml</mapping-file>
<mapping-file>ru/lanit/ps/registry/model/rterritory.xml</mapping-file>
<mapping-file>ru/lanit/ps/registry/model/stateowner.xml</mapping-file>
<properties>
<property name="com.intellij.javaee.persistence.datasource" value="Datasource"/>
<property name="toplink.logging.level" value="FINE"/>
<property name="toplink.jdbc.driver" value="org.hsqldb.jdbcDriver"/>
<property name="toplink.jdbc.url" value="jdbc:hsqldb:mem:PUBSER"/>
<property name="toplink.jdbc.password" value=""/>
<property name="toplink.jdbc.user" value="sa"/>
</properties>
</persistence-unit>
</persistence>
All my classes are inherited from StateOwner.class and only the RTerritory class has "one-to-many" and "many-to-one" relationships. When I add rterritory.xml to persistence.xml I have the following error (before all works fine):
log4j:WARN No appenders could be found for logger (org.springframework.context.support.ClassPathXmlApplicationContext).
log4j:WARN Please initialize the log4j system properly.
[TopLink Config]: 2007.12.18 02:47:15.812--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.Long ru.lanit.ps.registry.model.StateOwner.getId()] is being defaulted to: ID.
[TopLink Config]: 2007.12.18 02:47:15.859--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.Long ru.lanit.ps.registry.model.StateOwner.getStateTerritoryId()] is being defaulted to: STATETERRITORYID.
[TopLink Config]: 2007.12.18 02:47:15.875--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.String ru.lanit.ps.registry.model.StateOwner.getStringId()] is being defaulted to: STRINGID.
[TopLink Config]: 2007.12.18 02:47:15.875--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.String ru.lanit.ps.registry.model.StateOwner.getStateStatus()] is being defaulted to: STATESTATUS.
[TopLink Config]: 2007.12.18 02:47:15.875--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.Long ru.lanit.ps.registry.model.StateOwner.getStateVersion()] is being defaulted to: STATEVERSION.
[TopLink Config]: 2007.12.18 02:47:15.890--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.String ru.lanit.ps.registry.model.StateOwner.getStateAuthor()] is being defaulted to: STATEAUTHOR.
[TopLink Config]: 2007.12.18 02:47:15.890--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.sql.Timestamp ru.lanit.ps.registry.model.StateOwner.getStateCreationDate()] is being defaulted to: STATECREATIONDATE.
[TopLink Config]: 2007.12.18 02:47:15.890--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.sql.Timestamp ru.lanit.ps.registry.model.StateOwner.getStateModificationDate()] is being defaulted to: STATEMODIFICATIONDATE.
[TopLink Config]: 2007.12.18 02:47:15.890--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.lang.String ru.lanit.ps.registry.model.StateOwner.getStateComment()] is being defaulted to: STATECOMMENT.
[TopLink Config]: 2007.12.18 02:47:15.906--ServerSession(25709120)--Thread(Thread[main,5,main])--The column name for element [public java.sql.Timestamp ru.lanit.ps.registry.model.StateOwner.getStateProcessedDate()] is being defaulted to: STATEPROCESSEDDATE.
[TopLink Config]: 2007.12.18 02:47:15.906--ServerSession(25709120)--Thread(Thread[main,5,main])--The discriminator column name for the root inheritance class [class ru.lanit.ps.registry.model.StateOwner] is being defaulted to: DTYPE.
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'GroundOfRefusalServiceTarget' defined in class path resource [groundofrefusal.xml]: Cannot resolve reference to bean 'GroundOfRefusalDao' while setting bean property 'dao'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'GroundOfRefusalDao' defined in class path resource [groundofrefusal.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [openJPAsettings.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.lang.NullPointerException
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'GroundOfRefusalDao' defined in class path resource [groundofrefusal.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [openJPAsettings.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.lang.NullPointerException
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [openJPAsettings.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.lang.NullPointerException
Caused by: javax.persistence.PersistenceException: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.lang.NullPointerException
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.predeploy(EntityManagerSetupImpl.java:615)
at oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.createContainerEntityManagerFactory(EntityManagerFactoryProvider.java:178)
at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:218)
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:251)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1099)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:861)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:421)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1099)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:861)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:421)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:91)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:75)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65)
at ru.lanit.ps.registry.VerifyApplicationContext.setUp(VerifyApplicationContext.java:44)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at org.junit.internal.runners.BeforeAndAfterRunner.invokeMethod(BeforeAndAfterRunner.java:74)
at org.junit.internal.runners.BeforeAndAfterRunner.runBefores(BeforeAndAfterRunner.java:50)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:33)
at org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71)
at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at com.intellij.rt.junit4.Junit4ClassSuite.run(Junit4ClassSuite.java:78)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:40)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
Caused by: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.lang.NullPointerException
at oracle.toplink.essentials.exceptions.EntityManagerSetupException.predeployFailed(EntityManagerSetupException.java:212)
... 61 more
Caused by: java.lang.NullPointerException
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.OneToManyAccessor.process(OneToManyAccessor.java:142)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.RelationshipAccessor.processRelationship(RelationshipAccessor.java:275)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProject.processRelationshipDescriptors(MetadataProject.java:564)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProject.process(MetadataProject.java:497)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProcessor.processAnnotations(MetadataProcessor.java:231)
at oracle.toplink.essentials.ejb.cmp3.persistence.PersistenceUnitProcessor.processORMetadata(PersistenceUnitProcessor.java:354)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.predeploy(EntityManagerSetupImpl.java:584)
... 60 more
Process finished with exit code -1
This is my RTerritory.class and rterritory.xml
public class RTerritory extends StateOwner {
private static final long serialVersionUID = 5372570539234097349L;
//link to parent
private RTerritory parentTerritory;
//title
private String title;
//string type
private String type;
//Level
private Integer level;
//set of children
private Set<RTerritory> children = new HashSet<RTerritory>(0);
public RTerritory() {
public RTerritory(Long RTerritory, String title, String type) {
setId(RTerritory);
this.title = title;
this.type = type;
public RTerritory(Long id, RTerritory parentTerritory, String title, String type, Integer level) {
super(id);
this.parentTerritory = parentTerritory;
this.title = title;
this.type = type;
this.level = level;
public RTerritory(Long RTerritory, RTerritory parentTerritory, String title,
String type, Set<RTerritory> RTerritories) {
setId(RTerritory);
this.parentTerritory = parentTerritory;
this.title = title;
this.type = type;
this.children = RTerritories;
public RTerritory(Long id, RTerritory parentTerritory, String title, String type, Integer level, Set<RTerritory> children) {
super(id);
this.parentTerritory = parentTerritory;
this.title = title;
this.type = type;
this.level = level;
this.children = children;
public Integer getLevel() {
return level;
public void setLevel(Integer level) {
this.level = level;
public RTerritory getParentTerritory() {
return this.parentTerritory;
public void setParentTerritory(RTerritory parent_Territory) {
this.parentTerritory = parent_Territory;
public boolean hasParentTerritory() {
return getParentTerritory() != null;
public String getTitle() {
return this.title;
public void setTitle(String title) {
this.title = title;
public String getType() {
return this.type;
public void setType(String type) {
this.type = type;
public Set<RTerritory> getChildren() {
return this.children;
public void setChildren(Set<RTerritory> children) {
this.children = children;
public void addChildTerritory(RTerritory territory) throws Exception {
if (children != null && territory != null) {
children.add(territory);
territory.setParentTerritory(this);
} else {
throw new Exception("Parameter is null or children is null");// TODO throw exception ?
public void removeChildTerritory(RTerritory territory) {
if (children != null && territory != null) {
children.remove(territory);
territory.setParentTerritory(null); // TODO territory.setParentTerritory(this.getParentTerritory()) ?
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
if (!super.equals(o)) return false;
RTerritory that = (RTerritory) o;
if (level != null ? !level.equals(that.level) : that.level != null) return false;
if (title != null ? !title.equals(that.title) : that.title != null) return false;
if (type != null ? !type.equals(that.type) : that.type != null) return false;
return true;
public int hashCode() {
int result = super.hashCode();
result = 31 * result + (title != null ? title.hashCode() : 0);
result = 31 * result + (type != null ? type.hashCode() : 0);
result = 31 * result + (level != null ? level.hashCode() : 0);
return result;
@Override
public boolean isReference() {
return true;
<?xml version="1.0" encoding="UTF-8"?>
<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm"
version="1.0">
<package>ru.lanit.ps.registry.model</package>
<entity class="RTerritory" name="RTerritory">
<table name="reg_r_territory"/>
<primary-key-join-column name="R_TERRITORY" referenced-column-name="STATUS_ID"/>
<attribute-override name="id">
<column name="R_TERRITORY"/>
</attribute-override>
<attributes>
<basic name="title">
<column length="256" name="TITLE" nullable="false"/>
</basic>
<basic name="type">
<column length="256" name="TYPE" nullable="false"/>
</basic>
<basic name="level">
<column name="LEVEL"/>
</basic>
<!--<many-to-one name="parentTerritory" target-entity="RTerritory">
<join-column name="PARENT_TERRITORY_ID"/>
<cascade>
<cascade-persist/>
<cascade-merge/>
<cascade-refresh/>
</cascade>
</many-to-one>-->
<one-to-many name="children" mapped-by="parentTerritory" target-entity="RTerritory">
<cascade>
<cascade-all/>
</cascade>
</one-to-many>
<transient name="parentTerritory"/>
<!--<transient name="children"/>-->
</attributes>
</entity>
</entity-mappings>
If I make "parentTerritory" and "children" transient - all works well. Above workes also (comment out and without transient) on OpenJpa.
What do I do wrong if I use TopLink?
This is part of my applicationContext.xml
<bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
<property name="persistenceXmlLocation"
value="/META-INF/persistence.xml"/>
<property name="jpaVendorAdapter">
<bean class="org.springframework.orm.jpa.vendor.TopLinkJpaVendorAdapter"/>
</property>
<property name="loadTimeWeaver">
<bean class="org.springframework.instrument.classloading.InstrumentationLoadTimeWeaver"/>
</property>
</bean
Thanks a lot.Hello.
Thanks a lot for answer.
When I comment out and remove transient I obtain the following exception:
Internal Exception: java.util.NoSuchElementException
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.predeploy(EntityManagerSetupImpl.java:615)
at oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.createContainerEntityManagerFactory(EntityManagerFactoryProvider.java:178)
at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:218)
at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:251)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1099)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:861)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:421)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1099)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:861)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:421)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:91)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:75)
at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65)
at ru.lanit.ps.registry.VerifyApplicationContext.setUp(VerifyApplicationContext.java:44)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at org.junit.internal.runners.BeforeAndAfterRunner.invokeMethod(BeforeAndAfterRunner.java:74)
at org.junit.internal.runners.BeforeAndAfterRunner.runBefores(BeforeAndAfterRunner.java:50)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:33)
at org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71)
at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at com.intellij.rt.junit4.Junit4ClassSuite.run(Junit4ClassSuite.java:78)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:40)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90)
Caused by: Exception [TOPLINK-28018] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
Exception Description: predeploy for PersistenceUnit [registry] failed.
Internal Exception: java.util.NoSuchElementException
at oracle.toplink.essentials.exceptions.EntityManagerSetupException.predeployFailed(EntityManagerSetupException.java:212)
... 61 more
Caused by: java.util.NoSuchElementException
at java.util.AbstractList$Itr.next(AbstractList.java:427)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataDescriptor.getPrimaryKeyFieldName(MetadataDescriptor.java:539)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.ObjectAccessor.processOneToOneForeignKeyRelationship(ObjectAccessor.java:113)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.ObjectAccessor.processOwningMappingKeys(ObjectAccessor.java:190)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.ManyToOneAccessor.process(ManyToOneAccessor.java:106)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.RelationshipAccessor.processRelationship(RelationshipAccessor.java:275)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataDescriptor.getMappingForAttributeName(MetadataDescriptor.java:486)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.RelationshipAccessor.getOwningMapping(RelationshipAccessor.java:122)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.OneToManyAccessor.process(OneToManyAccessor.java:142)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.accessors.RelationshipAccessor.processRelationship(RelationshipAccessor.java:275)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProject.processRelationshipDescriptors(MetadataProject.java:564)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProject.process(MetadataProject.java:497)
at oracle.toplink.essentials.internal.ejb.cmp3.metadata.MetadataProcessor.processAnnotations(MetadataProcessor.java:231)
at oracle.toplink.essentials.ejb.cmp3.persistence.PersistenceUnitProcessor.processORMetadata(PersistenceUnitProcessor.java:354)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.predeploy(EntityManagerSetupImpl.java:584)
... 60 more
Process finished with exit code -1
I want to say that exception is same and I don't use GlassFish I run Unit test.
This is my rterritory.xml now:
<?xml version="1.0" encoding="UTF-8"?>
<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm"
version="1.0">
<package>ru.lanit.ps.registry.model</package>
<entity class="RTerritory" name="RTerritory">
<table name="reg_r_territory"/>
<primary-key-join-column name="R_TERRITORY" referenced-column-name="STATUS_ID"/>
<attribute-override name="id">
<column name="R_TERRITORY"/>
</attribute-override>
<attributes>
<basic name="title">
<column length="256" name="TITLE" nullable="false"/>
</basic>
<basic name="type">
<column length="256" name="TYPE" nullable="false"/>
</basic>
<basic name="level">
<column name="LEVEL"/>
</basic>
<many-to-one name="parentTerritory" target-entity="RTerritory">
<join-column name="PARENT_TERRITORY_ID"/>
<cascade>
<cascade-persist/>
<cascade-merge/>
<cascade-refresh/>
</cascade>
</many-to-one>
<one-to-many name="children" mapped-by="parentTerritory" target-entity="RTerritory">
<cascade>
<cascade-all/>
</cascade>
</one-to-many>
<!--<transient name="parentTerritory"/>
<transient name="children"/>-->
</attributes>
</entity>
</entity-mappings>
I can't understand What do I do wrong when I include "one-to-many" and "many-to-one" mapping? I want to note it (above mapping) works rightly if I use OpenJpa and one works rightly with TopLink if I remove one-to-many and many-to-one and do them transient.
Thanks a lot.
Message was edited by:
user610937
Message was edited by:
user610937 -
Toplink - Many-to-Many Mapping issue
Hi
I have the following tables
User
Place
Team
User : uid , name (where uid is primay key)
Place : uid , pid( where uid and pid are composite primary keys)
Team : tid , name , pid( where tid is primary key)
Here the following mappings :
one user is belongs to many places
one user have many teams( by place)
user have many teams
i have created many to many mapping between place(or user) and team tables using intermediate table user_team( uid ,tid). But when i try to retrieve the teams for user id then i m getting all the teams. Here i need to filter the teams by only place id instead getting all the teams.
For example:
if user id is belongs to place id 101 then i need to get only teams belongs to place id 101. But i m getting all the places(101,102) teams for same user id which belongs to place id 101.
Please help me out how i can create valide mapping between all the tables to retrieve valid data. i m using toplink workbench(10g - 9.0.4).Your model seems confused, you may wish to re-think you model. It seems odd that a place would have a user id, seems more like it is a m-m join table between user and team, but then it should have a team id not a place id.
You can use a selectionCriteria() on a ManyToManyMapping to define complicated m-m joins, but you would probably be better re-thinking your model. What object model are you trying to do exactly? Go from there, then define your data-model.
-- James : http://www.eclipselink.org -
Many-to-One user mapping to backend systems - possible?
My apologies if this simple question has been asked many times earlier - I couldn't find it if it is so.
I understand I can use user-mapping in single signon to map user X in portal to user A in backend system (say SAP BI).
Can I map users X, Y, Z..... to one backend user A?
What alternative I have (to let a number of portal users run some BW reports on the backend system - for which we want to use only one BI user-id)?An easier more manageble way of doing this is to create a group and assign the group to a backend user. That will establish your many to one relationship.
We perform this for our vendors currently as they would like to see a single shopping cart in SRM.
Just be cautious on the manner in which you leverage your single user as you can experience several locked objects depending on how things are accessed. Another thing to consider is making the backend user a service user as this will also allow you to change the password mapping policies on the users as in many cases you will need to remap the users every N days depending on your systems security parameters.
Hope this helps. -
Crystal Report Many to One Query Config error when using DataSet.ReadXML me
When I build a dataset with this method numerous relations are automatically created. I then map these fields onto crystal reports with ADO.net data connection. However when I run the report the following error occurs:
CrystalDecisions.CrystalReports.Engine.InternalException: Cannot determine the queries necessary to get data for this report.Details:
This query cannot be performed. The link order requires many to one query configuration, which is not supported. Please rearrange the links.
If I remove the links (relations) i get duplicate data on the report. Is there any way to resolve this or a patch for the error?Hello, Mervin;
Since you are using ADO.NET dataset, is it possible to get all of the fields you need in one SQL Query outside of Crystal Reports?
If that is possible, you can use that dataset to create an XML or XSD file to use as the structure for your report.
VB
'Using the full path to the .xml file, include the schema
dataSet.WriteXml("C:\temp\test.xml", XmlWriteMode.WriteSchema)
or
dataSet.WriteXmlSchema("c:\temp\testXML.xsd")
Now create a new report with the ADO.NET(XML) connection and point to either the XML or XSD you created. XML is useful because you can view data in the report designer for final formatting of the report.
Now there is only one datasource and no linking is required in Crystal Reports. That should resolve the one to many issue.
Another useful tool is to group on the many and place all the fields normally in the detail section into that group header. Suppress the Detail and Group footer sections. The Group Header will now look like a Detail section and each distinct value will only appear once. You can group on one field or a combination (using a formula field) to get the results you need. Test this to be sure you do not miss anything you want to see.
Elaine -
EA4500 – Smart Wi-Fi interface and Windows Network Map issues
I purchased this Router about 2 weeks ago as a phased upgrade of our Home Network, primarily to enhance media streaming. It has the latest firmware preinstalled from the factory. Prior to the purchase and installation of the EA4500 Router I replaced my old Motorola SurfBoard SB6120 DOCSIS 3.0 Cable Modem with a Motorola SurfBoard SB6141 DOCSIS 3.0 Cable Modem. My old Linksys E2000 Router worked perfectly with the SB6141, with the exception that the E2000 wasn’t IPv6 enabled, but does have 10/100/1000Base-T Ethernet (RJ-45) and Internet ports.
The EA4500 has been installed for about 10 days and seems to have improved local network speeds and I don’t seem to be having any Internet connectivity issues. However, there are some disturbing issues with the EA4500 and the AE3000 I purchased. There are 11 devices connected through the Router; a Dell Desktop (wireless with the AE3000), a Dell Desktop (Ethernet), a Dell Laptop (wireless), 2 Canon Printers (1 Ethernet and 1 Wireless), 2 Western Digital 1TB MyBookLive Network Drives (both Ethernet), a WD TV Live Streaming Media Player (wireless), an Apple TV media player (wireless), an iPad (wireless), and an Android Smartphone (wireless).
Issue 1 – The Linksys Smart Wi-Fi interface appears to be unreliable at times!!! I’ve read about this problem here on the Community involving the EA6500, so I don’t know if this is a Linksys Server issue, as suggested in a few responses, or a bug in the Router firmware, or defective hardware. However, when the interface locks up, it can’t be accessed from a wireless or wired connection. Usually, powering down the Router and then powering it back up and restart will allow it to function again. However, at times before the interface completely locks up it shows either just a white screen or the security screen will show no firewall features enabled. This is a little scary, so I’ll do a complete reset and setup; this is becoming a pain in the rear!!!!! Is there any hope for this being fixed, in this Router, not the next generation??????????
Issue 2 - All of my network devices show up in the Router’s Device List. Except for the Apple devices they also show up, when they are online, in Windows 7 Explorer under Network and when you click on Network they are correctly displayed as Computers, Media Devices, Network Infrastructure, or Storage. However, when you click on “Open Network and Sharing Center” and then click on “See Full Map”; it fails with the response “Windows cannot create the network map. Responses from other devices on the network are delayed or there is an incompatible router on the network”; no device map is shown. When I follow the link for more information, the only thing that stands out is “A device on the network, such as a hub or switch, is not working properly or is not compatible with the Link Layer Topology Discovery (LLTD) protocol, which Windows uses to create the map. To fix this problem, disable the device, turn it off, or remove it from your network”. All of my network devices showed up on the Network Map with the old E2000. This issue is the same on all of my computers, either wired or wireless. Any known solutions for this, or is it as Windows suggests; an incompatible Router????
Thanks in advance for any insight or solutions. With the issues I’m having with the EA4500 and the AE3000; they are both probably going back to Amazon.thebluemamba_24; Thank you for your suggestion; I finally found time yesterday to perform an extensive evaluation before I return the Router. However, rather than trying to add devices manually, my rationale was if the EA4500 can’t process them correctly, automatically, it needs to be returned anyway, so I added devices normally letting the device an Router handle the process.
In thinking through this issue, all devices on our network are detected and identified by Windows Explorer on Windows 7 computers; except of course the Apple and Android devices (Apple TV, iPad, and Smartphone). So, I wondered if one of those three devices being added to the Router’s device list was somehow causing issues or interfering with Windows 7’s ability to generate a Network Map. Therefore, my approach was to turn off or disable all devices on our network, reset the Router to factory defaults, reestablish the Router to my custom Home Network configuration using a Windows 7 PC that has LAN and Wireless access to the Router, then add one device at a time and check with each addition to see if Windows 7 could still generate a Network Map.
With the Router reset and reestablishment complete; I began the process of adding one device at a time and checking to see if a Network Map was being generated. What I discovered was when a recent addition to the network, a Western Digital WD TV Live Streaming Media Player, was connected (wirelessly), Windows 7 could no longer generate the Network Map and the failure was consistent. The only way to get the Network Map to work again was to remove power from the WD TV Live, although it remained in the EA4500’s Device List; simply turning it off didn’t help. Since I’d originally witnessed the Windows 7 Network Map working with the Linksys E2000 Router that the EA4500 replaced, I decided to test the WD TV Live with that Router. It worked initially, but it failed consistently after the first success. Interestingly, the failure indication was a little different, but nevertheless generation of the Network Map failed.
I’ve tried changing a few settings on the EA4500 as well as the WD TV Live, but nothing helped. There was a recent firmware update to the WD TV Live, so I might try rolling back the firmware to see if it makes a difference.
The Network Map issue might very well be an issue with the WD TV Live, not the Router, but after reading many threads on this Community I have reservations that the problems I’m experiencing with the Smart interface lockup will be fixed. I suspect new emerging replacement products will be the focus and these older products will be abandoned and no more firmware fixes will be forthcoming and I don’t want to spend more money for a new product just to fix old problems and get something that works properly. The Network Map issue is troublesome, but the lockup of the Router’s “Linksys Smart Wi-Fi” interface is a serious matter to me. It appears that once it locks up, the only way to correct it is a power off restart; not practical if you’re traveling and trying to access settings remotely; the selling point for this feature.
Given the problems I’m experiencing with the EA4500 and AE3000, I guess I’ll return them. Too bad, because otherwise the EA4500 seems like it’s a good Router. I’ve been brand loyal since the Linksys WRT54G came out, but after reading this Community and with my personal experience with the EA4500 and AE3000, now I’ll probably give the NETGEAR N900 equivalents a try. -
Mapping issues while using MapwithDefault Node function for Idoc
Hi Experts,
We are facing issues while trying to generate nodes at reciver side even though it does not exist at sender side.
we are using the matmas05 and we want the nodes E1marcm and e1mardm to generated at target structure.
the structure is like this
Matmas05
idoc
E1maram
segment
E1marcm
segment
msgfn
.....other fields
E1mardm (can be many segments)
segment
lgort
..other fields
E1mpgdm
segment
...e1mpgdm fields
the mapping has been done like:
e1marcm -mapwithdefault-e1marcm
constant -segment
werks-mapwithdefault-werks
other fields(one to one mapping)
e1mardm-mapwith default-e1mardm
lgort-mapwithdefault(value 1000)-lgort
other fields -one to one mapping
now the problem we are facing is when e1mardm is not existing in source structure the values from the other node of e1mardm(which exists) are getting overwritten into it.
we want only the lgort to be 1000 and the segment should populate at target side.
like
e1mardm
segment
lgort value 1000
Could you please assist in solving this issue and give your valuable suggestions as how could we handle it.
Thanks and regards,
jyotiU will achieve this using UDF function. Map the below Like.
e1mardm-mapwith default(Value Constant)-e1mardm
lgort (A) ---
e1mardm-mapwith default(Value Exit)u2014(EqualsS) (B)- (UDF1)- lgort
Constant(Value Exit)---
Constant(Value 1000)(C)---
Other one to one mapping fields also you should use one more UDF.
Other one to one fields (A) ---
e1mardm-mapwith default(Value Exit)u2014(EqualsS) (B) - (UDF2)- Target
Constant(Value Exit)---
UDF1:
Argument A,B,C and select queue.
//write your code here
int j = 0;
for(int i=0;i<a.length;i++)
if (b[j].equals("true"))
result.addValue(c[0]);
i--;
result.addValue(ResultList.CC);
else
result.addValue(a<i>);
j++;
UDF2:
Argument A,B and select queue.
//write your code here
int j = 0;
for(int i=0;i<a.length;i++)
if (b[j].equals("true"))
i--;
result.addValue(ResultList.CC);
else
result.addValue(a<i>);
j++; -
Hi
Has anyone come across a mapping issue between the OTLR Timecard Window to BEE?
It would seem that hours are logged correctly in the timecard window after running the first Transfer concurrent process, but after re-running it to move it into the BEE, it incorrectly moves hours into Pay Value in error. Has anyone else come across this, is there a patch available to fix the problem? This is obviously a major issue as payment is therefore incorrect as a result. I can't imagine that no-one else has come across this problem, as they are seeded processes we are running.
It seems to be fine if you transfer straight to BEE without first moving it into the OTLR Timecard window... STRANGE.
Any help would be much appreciated.
Many thanks
CharlieAlso if that does not help, typically, that error is caused because the Windows application server can't resolve the netbios name of the SGD server. To resolve this, if you are using a WINS server on the Windows box point it to a WINS server that can resolve the netbios name of the SGD server. Alternatively, and most simplest, edit the lmhost file on the Windows
server by default found at:
/windows/system32/drivers/etc
and include the netbios name and address of the SGD server e.g
121.121.121.10 sgdserver sgdserver.domain.com
NOTE: The netbios name is by default the SGD Peer DNS name -
XSLT mapping issue in parent child relation
Hi Guys,
i have one XSLT mapping issue. Mapping scenario is from IDoc to file.
IDoc structure is as below
<ZLOIPRO1>
<E1AFKOL>
<A></A>
<B></B>
<E1RESBL>
<MATNR>1</MATNR>
<CHARG>1</CHARG>
<ZSBL>
<MTART>ABC</MTART>
</ZSB>
</E1RESBL>
<E1RESBL>
<MATNR>2</MATNR>
<CHARG>2</CHARG>
<ZSBL>
<MTART>ZHA1</MTART>
</ZSB>
</E1RESBL>
<E1RESBL>
<MATNR>3</MATNR>
<CHARG>3</CHARG>
<ZSBL>
<MTART>ZHA1</MTART>
</ZSB>
</E1RESBL>
</E1AFKOL>
</ZLOIPRO1>
As you can see 'E1RESBL' is repeatative. Now my issue is i need to select 'MATNR' and 'CHARG' from 'E1RESBL' segment when first occurance of 'ZSBL/MTART' with value 'ZHA1' appears. i.e. my output would be MATNR = 2 and CHARG = 2.
I hope i am clear. Please let me know if any solution for this.Hi,
Try this
<xsl:if test="./ZSBL/MTART == 'ZHA1'">
<xsl:for-each select="./E1RESBL">
<MATNR>
<xsl:value-of select="./MATNR"/>
</MATNR>
<BATCH>
<xsl:value-of select="./CHARG"/>
</BATCH>
</xsl:for-each>
</xsl:if>
You might need to do some changes in the above.
Thanks,
Prakash -
Hi All,
Please can you guys put your little valuable time to help me in this. I have got one scenario like xml files to xml file, with one outbound interface to one inbound interface. These input 'n' xmls are coming into the folder in 5 to 10 minutes time. I want to merge all 'n' number of xmls into one xml.
'n' number of input all files are comes in same structure, file names are like MTT_006669800_1.xml, MTT_00666801_2.xml,....
MTT_006670300_1.xml, MTT_006670301_2.xml .... MTT_006670310_10.xml etc.,
the above two files are coming from 2 different divisions. Division numbers are in the file like 006669,006670 etc.,
But I need to pickup only one division all files first then goto Second division. These 'n' number picked files parse it and keep into one file as follows:
Input files structure
<ROOT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
</ROOT>
=========================
Output file Structure
<ROOT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
<OUTPUT>
<Product1>..</Product1>
<Product2>..</Product2>
</OUTPUT>
</ROOT>
To this above scenario I have implemented BPM (As what SAP pattern says - Payload collect) with block,loop,Receive, multi line Container, Counter Container, after block Transformation step and Send step.
I am using graphical mapping source side 0..n occurrence --> 1 occurrence (one to one mapping)
Sender file adapter Process mode I have taken append.
The problem is it is clubbing but the all file namespaces etc., coming into one file. I can't able to open that xml.
I can't put the target file with different name too.
Please correct me where I am making mistakes.
Thanks in advance.
Kind Regards
SanHi Raj,
Many thanks for your quick reply. But one thing I have noticed here. If you take Append mode, I can't able to change file name for division wise. Second thing the append mode appending header lines
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<ns1:ROOT xmlns:ns1="urn:xxx:snc:productactivedata">
are also coming in target xml file. Am I making any mistakes in mapping??
Messages Messages
Message1 Message1
ROOT -
> ROOT
OUTPUT -
> OUTPUT
Product 1 -
> Product 1
Product 2 -
> Product 2
Please little bit more idea on this!!
Many Thanks
Regards
San -
Mapping issue in idoc to JDBC scenario
mapping issue in idoc to JDBC scenario
source structure
E1KNB1M
BUKRS = 1000
E1KNB1M
BUKRS= 9000
E1KNB1M
BUKRS= 2000
THE NODE E1KNB1M is repeated many times and the field BUKRS is also repeated with E1KNB1M as above
TARGET field : ISFRANCHISE
if any where value of BUKRS =9000 we have to pass Y to the target filed, else N
if BUKRS = 9000 THEN ISFRANCHISE= Y
ELSE
ISFRANCHISE=N
I've done the mapping as below
BUKRS = 9000--> IF THEN Y ELSE N--
> ISFRANCHISE
BUT everry time the target value is N only
pl suggest
rgds
mojibmapped like this
BUKRS--->SORT---->
EQUALS --------IF---THEN Y
9000------------------------> ----------------->ISFRANCHISE
ELSE N
context of BUKRS set to parent node
its worked
thanks to all for valuable suggestions
rgds
mojib
Maybe you are looking for
-
SSO with SAP R/3 with load balancing as backend over the Web AS
Hi, we have Netweaver 2004 at this time and we have to connect the portal to a BSP application in a load balancing environment. We set user mapping for the user and set the connection type from SAPLOGONTICKET to UIDPW. This is running for a test envi
-
My speakers dont work , headphone jacks do
-
everytime i plug my camera to my ibook to transfer my pictures to my g4 it seems that my laptop wont read it,i cant find my photo library how can i install it again?please help
-
Transport of the Project (TC - CMOD)
Hi, I have a project created in CMOD in which I have many user exit variables. Can someone help me how do I transport the same to quality. I have transported the queries which are using these variables. However I am not able to transport these variab
-
Convert Date to String but maintain a MM/DD/YY format
I have converted a date field to a string without a problem. However, when I use it in a report, the entire date/time from the original date field prints. How do I get only the MM/DD/YY format to print once I've converted it to a string or how do