Error with variable substitution..
Hi
I am getting following error message for variable substitution
*Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: date_stamp: com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: date_stamp
<?xml version="1.0" encoding="UTF-8" ?>
- <I813_EModMCS_IB_MT>
- <Records>
<ModMod>111</ModMod>
<DesModdcr>222</DesModdcr>
- <Date_Stamp>
<Date_Stamp>20080338</Date_Stamp>
</Date_Stamp>
</Records>
</I813_EModMCS_IB_MT>
date_stamp payload:I813_EModMCS_IB_MT,1,Records,2,Date_Stamp,3,Date_Stamp,1
Would appriciate if you can correct the variable substitution...
Regards
To reference the element that is in bold in the example, the following expression is used: payload:root,1,e1,1,e2,2
The parser searches for the first occurrence of the root element at the first level. It then searches for the first occurrence of e1 at the second level and for the second occurrence of e2 at the third level. The content of the last element (u201CExample Valueu201D) is set as the value for a specified variable.
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<dummy>
<e1>
<e2>Data_1</e2>
<f/>
<g attr="abc">text</g>
<e2>Data_2</e2>
</e1>
</dummy>
<e1>
<e2>illegal/value</e2>
<f/>
<g attr="abc">text</g>
<e2 attr="fghij">Example Value</e2>
</e1>
</root>
Edited by: Progirl Progirl on Jul 17, 2008 8:04 AM
Similar Messages
-
Error file adapter with variable substitution in PI 7.31
Hello,
I'm trying to create a file with a dynamic name, based on the payload of the message.
We're trying to create a filename with the bold content in the name %batchId%.xml. The subtitution we use is
payload:batch,1,batch-info,1,id,1
<ns1:batch xmlns:ns1="http://www.atosworldline.com/archivingPortal/receivers">
- <ns1:batch-info id="test" isTest="true">
<ns2:sender-identifier xmlns:ns2="http://www.atosworldline.com/archivingPortal/batchInfo">String 2</ns2:sender-identifier>
<ns2:nb-elements xmlns:ns2="http://www.atosworldline.com/archivingPortal/batchInfo">3</ns2:nb-elements>
<ns2:batch-integration-mode xmlns:ns2="http://www.atosworldline.com/archivingPortal/batchInfo">String 4</ns2:batch-integration-mode>
<ns2:creation-datetime xmlns:ns2="http://www.atosworldline.com/archivingPortal/batchInfo">1999-05-31T13:20:00Z</ns2:creation-datetime>
</ns1:batch-info>
- <ns1:receivers>
- <ns1:receiver>
<ns1:id>String 5</ns1:id>
<ns1:action>String 6</ns1:action>
<ns1:contact-details />
- <ns1:tokenSets>
- <ns1:tokenSet startDate="1999-05-31T13:20:00Z" endDate="1999-05-31T13:20:00Z">
- <ns1:token>
<ns1:tokenvalue>String 7</ns1:tokenvalue>
</ns1:token>
- <ns1:token>
<ns1:tokenvalue>String 9</ns1:tokenvalue>
</ns1:token>
</ns1:tokenSet>
- <ns1:tokenSet startDate="1999-05-31T13:20:00Z" endDate="1999-05-31T13:20:00Z">
- <ns1:token>
<ns1:tokenvalue>String 11</ns1:tokenvalue>
</ns1:token>
- <ns1:token>
<ns1:tokenvalue>String 13</ns1:tokenvalue>
</ns1:token>
</ns1:tokenSet>
</ns1:tokenSets>
</ns1:receiver>
</ns1:receivers>
</ns1:batch>
The following error is shown, when processing the message through the receiving fileadapter.
MP: exception caught with cause com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: batchId
kind regards,
PieterAFAIK - Variable substitution does not support attributes. It only support the elements. (- <ns1:batch-info id="test" isTest="true">)
May be you can go with dynamic configuration instead of variable substitution. -
Problem with variable substitution.
Hello,
I asked this before but now I want to change the question focus.
I have scenario from IDOC to XML file.
The scenario is digital invoice for our company in Mexico and I end this scenario with java mapping that I import from SAP marketplace.
Now I have request to add to the XML file name the content of the field "<ODN_NUMBER>" from the XML data.
I try to use with variables substitution.
My payload is:
<?xml version="1.0" encoding="UTF-8" ?>
- <ZINVOIC02>
- <IDOC BEGIN="1">
- <EDI_DC40 SEGMENT="1">
<TABNAM>EDI_DC40</TABNAM>
<MANDT>400</MANDT>
<DOCNUM>0000000006599015</DOCNUM>
<DOCREL>700</DOCREL>
<STATUS>30</STATUS>
<DIRECT>1</DIRECT>
<OUTMOD>2</OUTMOD>
<IDOCTYP>INVOIC02</IDOCTYP>
<CIMTYP>ZINVOIC02</CIMTYP>
<MESTYP>INVOIC</MESTYP>
<STDMES>ZEDI</STDMES>
<SNDPOR>SAPDEV</SNDPOR>
<SNDPRT>LS</SNDPRT>
<SNDPRN>DEV400ECC</SNDPRN>
<RCVPOR>SAPDEV</RCVPOR>
<RCVPRT>LS</RCVPRT>
<RCVPFC>LS</RCVPFC>
<RCVPRN>MX_INV</RCVPRN>
<CREDAT>20100118</CREDAT>
<CRETIM>075931</CRETIM>
<SERIAL>20100118075931</SERIAL>
</EDI_DC40>
- <E1EDK01 SEGMENT="1">
<CURCY>USD</CURCY>
<HWAER>MXN</HWAER>
<WKURS>10.55530</WKURS>
<ZTERM>0090</ZTERM>
<KUNDEUINR>ACH971209KRA</KUNDEUINR>
<BSART>INVO</BSART>
<BELNR>0100017295</BELNR>
<BRGEW>0.045</BRGEW>
<GEWEI>KGM</GEWEI>
<FKART_RL>LR</FKART_RL>
<RECIPNT_NO>0000012977</RECIPNT_NO>
<FKTYP>L</FKTYP>
- <Z1EDK01 SEGMENT="1">
<XML_VERSION>2.0</XML_VERSION>
<ODN_PREFIX>A</ODN_PREFIX>
<ODN_NUMBER>1883</ODN_NUMBER>
<DATE_TIME>2009-11-01T17:05:10</DATE_TIME>
<DOC_SUB_TOTAL>4.22</DOC_SUB_TOTAL>
<DOC_DISCOUNT>3.00</DOC_DISCOUNT>
<DOC_TOTAL>1.40</DOC_TOTAL>
</Z1EDK01>
And the xml that I create is:
<?xml version="1.0" encoding="utf-8" ?>
- <Comprobante xmlns="http://www.sat.gob.mx/cfd/2" version="2.0" serie="A" folio="1883" fecha="2009-11-01T17:05:10" sello="NxZCWU8hMJMiEc2fSZafpS81Z9rUScbBotvJ8lcW76GGpmcD2lFyAV7DlNQKecYMnQJnwMVoHfGjzhpFJrjLuRcyqU3nOnH1mE1JMxY/MjLkal0Ybo2aRKCorQxx+F/Vy5ucvyeDDFAt2gx0PeHJhFS3tJ6ssc6nryz3iUr8c=" noAprobacion="49806" anoAprobacion="2009" formaDePago="Pago en una sola exhibiciףn" noCertificado="00001000000100891274" condicionesDePago="90 DAYS FROM BILL OF LADING" subTotal="4.22" descuento="3.00" motivoDescuento="Customer DiscountCustomer Discount" total="1.40" tipoDeComprobante="ingreso">
- <Emisor rfc="NMS940324RY6" nombre="Netafim Mexico S.A. de C.">
<DomicilioFiscal calle="Leibnitz" noExterior="20" noInterior="901" colonia="Anzures" localidad="Mexico city" municipio="Miguel Hidalgo" estado="Distrito Federal" pais="Mexico" codigoPostal="11590" />
</Emisor>
- <Receptor rfc="ACH971209KRA" nombre="AGRICOLA 5 HERMANOS SA DE CV">
<Domicilio calle="JUAN DE LA BARRERA NO 1249 NORTE" localidad="COL. CHAPULTEPEC" municipio="CULIACAN" estado="Sinaloa" pais="Mexico" codigoPostal="80040" />
</Receptor>
- <Conceptos>
I try to use with this variable:
payload:ZINVOIC02,1,IDOC,1,E1EDK01,1,Z1EDK01,1,ODN_NUMBER,1
I received in RWB the error:
Attempt to process file failed with com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: var_filename
Thank you in advance for your help
EladBut my target is looks very strange:
<?xml version="1.0" encoding="utf-8" ?>
- <Comprobante xmlns="http://www.sat.gob.mx/cfd/2" version="2.0" serie="A" folio="1883" fecha="2009-11-01T17:05:10" sello="NxZCWU8hMJMiEc2fSZafpS81Z9rUScbBotvJ8lcW76GGpmcD2lFyAV7DlNQKecYMnQJnwMVoHfGjzhpFJrjLuRcyqU3nOnH1mE1JMxY/MjLkal0Ybo2aRKCorQxx+F/Vy5ucvyeDDFAt2gx0PeHJhFS3tJ6ssc6nryz3iUr8c=" noAprobacion="49806" anoAprobacion="2009" formaDePago="Pago en una sola exhibiciףn" noCertificado="00001000000100891274" condicionesDePago="90 DAYS FROM BILL OF LADING" subTotal="4.22" descuento="3.00" motivoDescuento="Customer DiscountCustomer Discount" total="1.40" tipoDeComprobante="ingreso">
- <Emisor rfc="NMS940324RY6" nombre="Netafim Mexico S.A. de C.">
<DomicilioFiscal calle="Leibnitz" noExterior="20" noInterior="901" colonia="Anzures" localidad="Mexico city" municipio="Miguel Hidalgo" estado="Distrito Federal" pais="Mexico" codigoPostal="11590" />
</Emisor>
- <Receptor rfc="ACH971209KRA" nombre="AGRICOLA 5 HERMANOS SA DE CV">
<Domicilio calle="JUAN DE LA BARRERA NO 1249 NORTE" localidad="COL. CHAPULTEPEC" municipio="CULIACAN" estado="Sinaloa" pais="Mexico" codigoPostal="80040" />
</Receptor>
I need to add folio field
Elad -
Error in Variable Substitution
Dear All,
Result Payload:
<ns1:MT_Level1 xmlns:ns1="http://test.com">
<Header>
<Separator>,</Separator>
</Header>
<Detail>
<FileNumber>30</FileNumber>
<LinkToNextLevel />
<Expansion1>0</Expansion1>
<Expansion2>0</Expansion2>
<Expansion3>0</Expansion3>
<Expansion4>0</Expansion4>
</Detail>
<Detail>
<FileNumber>30</FileNumber>
<LinkToNextLevel />
<Expansion1>0</Expansion1>
<Expansion2>0</Expansion2>
<Expansion3>0</Expansion3>
<Expansion4>0</Expansion4>
</Detail>
<FileNode>
<FileName>test.txt</FileName>
</FileNode>
</ns1:MT_Level1>
I want to use "File Name" in the "File Node" node for my variable substitution.
In the configuration:
File Name Scheme = %filename%
Variable = filename
reference = payload: Messages, 1, Message, 1, MT_Level1, 1, FileNode, 1, FileName, 1
Note: I'm using multimapping (1 to N).
File Name path is /ns0:Messages/ns0:Message2/ns1:MT_Level1/FileNode/FileName ( from right click in the file name --> copy path).
I got following error:
"Attempt to process file failed with com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: filename"
Please advise!
Best Regards,
Victor.Dear All,
My problem is solved!
The issue is because I don't put the interface mappings sequence as the same sequence as the message mappings sequence. Hence the structure name that i put in the variable substitution all are not match with the structure name in the payload even though all have the file name element.
So what i did is i have to reorder the sequence of my message mappings to be the same sequence as the interface mappings sequence.
Thanks for all that trying to help!
Appreciated it guys.
BTW, for the variable reference it's correct that i no need to put message and message2 as the reference.
payload:MT_Level1,1,FileNode,1,FileName,1 will do.
Best Regards,
Victor. -
Dynamic target directory with variable substitution
Hi everyone.
I'm trying to save a file in a folder with receiver adapter.
This folder is determined in runtime and passed to the adapter with variable substitution. My problem is that in RWB i get a error like this : 'Content of variable XXXXX is not safe'
Does anybody have done a variable substituion for output directory receiver file adapter?
Regards,
Inigo.Hi,
Check this links,
/people/sameer.shadab/blog/2005/09/23/an-interesting-usage-of-variable-substitution-in-xi
http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm
Regards,
Phani -
Error during Variable Substitution
Hi Experts,
Pls go through the errors
I am getting the following error in RWB>Messages Monitoring->Adapter Engine
It is in Production,
Many messages are successful but 40% messages are failed with this Error
The following is the Error log
Attempt to process file failed with
com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution:
com.sap.aii.adapter.file.varsubst.VariableDataSourceException: Caught SAXException while parsing XML payload:Fatal Error:com.sap.engine.lib.xml.parser.parserException: XMLparser: No data allowed here(:main:,row:,col:75)"
main:,row:,75 will be changing for every failure message
I have checked the XML payload also there is no problem.
if it has a problem, after rescending also it should not be processed
please find the different errors carefully and give me the Solution.
Getting different Errors for different messages like below
1.com.sap.engine.lib.xml.parser.parserException:XMLParser:N o data allowed here:(hex) 76,65,72 (:main:,row:1,col:9)
for the same message when the sys tried to resend
parserException:start-tag 'EIT' is different from the end-tag'E1EDP03(:main:,row:1,col:16)
2.com.sap.engine.lib.xml.parser.parserException:XMLParser:Declaration not allowed here:(:main:,row:1,col:6)
for the same message when the sys tried to resend
(:main:,row:1,col:89)
3.com.sap.engine.lib.xml.parser.parserException:XMLParser:Name Expected:0x0.(:main:,row:1,col:0)
for the same message when the sys tried to resend
:No data allowed:(hex)0(:main:,row:1,col:1)
4.com.sap.engine.lib.xml.parser.parserException:XMLParser:start-tag= 'EDI_DC40' is different from the end-tag= 'DOCNUM'(:main:,row:2,col:125)
for the same message when the sys tried to resend
parserException:</expected(:main:,row:1,col:0)
5.com.sap.engine.lib.xml.parser.parserException:XMLParser:</expected(:main:,row:2,col:1788)
when ever the sys tried to rescend the following errors are getting
XMLParser:</expected(:main:,row:2,col:17)
XMLParser:No data allowed here(:main:,row:2,col:96)
XMLParser:No data allowed here(hex)76, 65, 72(:main:,row:1,col:9)
XMLParser:Document is not well-formed:start-tag 'EDI_DC40' is different from end-tag 'DOCREL'(:main:,row:1,col:9)
For all these errors if we resend, the messages are processed successfully, if i select more messages then it won't be processed.
I have checked SMQ1 and even Javaengine also re-started but same problem.
I have checked payload message with above errors but there is no problem.
can any body give me the solution
Regards
RajanAvoid posting duplicate thread,
Exception during Variable Substitution
Regards -
Error during variable substitution: idoc to file
Hi Friends,
I have a got a issue which is Idoc to file scenario.
Iam getting the following error.
Attempt to process file failed with com.sap.aii.adapter.file.configuration.DynamicConfigurationException: Error during variable substitution: com.sap.aii.adapter.file.varsubst.VariableDataSourceException: The following variable was not found in the message payload: date_processing
Could you please tell me waht could be the reason for the same?
as per my analysis, I observed that the field date_processing has been declaredHi Sandeep ,
If the variable date_processing refers to an element in XML schema, Please check if you have added the prefix payload: to the information under Reference.
The reference then comprises a pseudo path description in the form of a comma-separated list with the schema namea,na,nameb,nb,....
Where namea,nameb,... corresponds to the element name and na,nb,... corresponds to the occurrence of the element name at the respective level in the document.
The description begins at the root of the document and ends at the respective element.
Also please check
Re: Variable substitution
Regards,
Jyoti -
Issue with Variable Substitution
Hi,
We have a scenario where we need to use the data from Payload for further processcing of the messeges.The payload looks like the one given below.
<?xml version="1.0" encoding="utf-8" ?>
- <ns1:MT_NOTIFICATION xmlns:ns1="http://WM_ERRHAND" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <PROXYRESPONSE>
<STATUS>YES</STATUS>
<NAMESPACE>WM_INVOICE</NAMESPACE>
<INTERFACENAME>MI_INVOICE_MOORE_ACK_IN</INTERFACENAME>
<PROXYNAME>ZXIII_MI_INVOICE_MOORE_ACK_IN</PROXYNAME>
</PROXYRESPONSE>
</ns1:MT_NOTIFICATION>
In adapter, for variable substitution we have specified as below:
payload:MT_NOTIFICATION,1,PROXYRESPONSE,1,NAMESPACE,1
but getting an error "Message processing failed: Error during variable substitution: java.text.ParseException: Variable 'namespace' not found in variable substitution table"
Is the variable that we have declared is right or is there anything we have missed out. Any helpful answers will be rewarded
Thanks and regards,
Ram.Hi Ram,
The substitution looks fine.
Did you read this,
<i>To disable the check the adapter performs for the element data, set the Disable Security Checks indicator.
Otherwise, the adapter checks whether the element data contains characters that could lead to security risks in the file system environment. The check includes the characters /, \, and ...</i>
Try seleting this option and checking the same.
Regards,
Bhavesh -
Filename in J2SE Adapter with Variable Substitution
Hello,
Within the J2EE receiver fileadapter (and ftp) from SP13 it is possible to compose the target filename and directory based on the payload of a message using variable substitution.
I wonder if it is also possible to use variable substitution with the J2SE fileadapter. For this it is not documented but i thougth that the same java libraries are used for the J2EE an J2SE file-adapters.
Aybody??
Really Nobody??
Message was edited by: Emile HermansHello,
the J2SE Adapter does not support variable subsition. Therefore we created our own class which gets called from the main SAP XI class "XMB2FileProcessor.class" wich is in the jar "aii_msg_adapter.jar". In your own class you can do what ever you need to chane the file name. In the configuration you can set your own parameter to search the payload for a string you want to replace. We also had to come up with our own timestamp, e.g. file2005-11-10 which SAP does not let you do, only the full timestamp is possible.
One other nice thing is that you can develop our JAVA class local and test it with your local J2SE Adapter Engine on you PC before you deploy it.
Steps to do:
1. JAD the SAP class
2. Put a call in the SAP class
3. Compile the class
4. Put the class back in the archive
5. Create your own class
6. Create a jar file for it
7. Put the jar file in the tech_adapter directory
8. Change the run_adapter start cmd to include your jar file
It works great, the only issue is if you patch the J2SE engine you have to do step 1 to 4 again but that should it very easy to do.
Cheers
Stefan -
Problem with Variable Substitution Receiver Adapter
Hi,
I need to use a dynamic filename so I'm using the variable substitution in my receiver adapter. BUT, the filename can't appear in the file. So i used this blog in reference --> Solution to the problem encountered using Variable Substitution with XI-SP12
The PROBLEM is I still get and extra blank line in the file. How can I eliminate this extra line?
Thanks in advance.
Using XI 7.0Hi Gaurav,
Data Type:
Lines
Line
Config
FileName
XML - example:
<?xml version="1.0" encoding="utf-8"?>
<nr1:MT_TP_TipoCambio_Detalle_ECC_Req xmlns:nr1="urn:erplatam/tipocambio:tp:ecc">
<Lines>
<Line>USDSOL0000000000003.10000013-09-200813-09-2008V</Line>
</Lines>
<Lines>
<Line>USDSOL0000000000002.50000014-09-200814-09-2008V</Line>
</Lines>
<Config>
<FileName>SIGMA_TCSAP_F081031.DAT.TXT</FileName>
</Config>
</nr1:MT_TP_TipoCambio_Detalle_ECC_Req>
Output - File, has 3 lines should have only 2:
USDSOL0000000000003.10000013-09-200813-09-2008V
USDSOL0000000000002.50000014-09-200814-09-2008V
FCC parameters:
RecordSet Structure: Lines,Config
Lines.fieldSeparator 'nl'
Lines.endSeparator 'nl'
Config.fieldSeparator 'nl'
Config.endSeparator 'nl'
Thanks in advance! -
Filename generation with variable substitution.
Hi,
I am currently working on a senerio in which file is receiver.The requirement is to generate file at target with the file name as message id.How can i use VARIABLE SUBSTITUTION and acheive this.
(Add message id in configuration should not be done.)Hello shruthi,
Please try this for the filename creation,
1. Create a UDF in the message mapping named getFileName, select only one input (to pass the messageid) and paste this coding there;
/* getFileName User Defined Function
// function to create name of output file
String filename;
filename = strFile;
try {
// initialize DynamicConfiguration for create file with given name
DynamicConfiguration conf = (DynamicConfiguration) container
.getTransformationParameters()
.get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create( "http://sap.com/xi/XI/System/File", "FileName");
//create file with the specified name
conf.put(key, filename);
} catch (Exception ex) {
return filename;
2. In the target structure header field perform this mapping,
Messageid -> getfFileName UDF -> Target Structure Headerfield
3. Then in the Integration directory under the target tab
check the Use - adapter specific message attributes and File Name
Please follow the steps and let me know if u still face the same problem. -
MapViewer Html5 API. Error with Variable Pie Chart Style Model
Hello,
I have a serious problem related to Variable Pie Chart Style. MapViewer - Mapbuilder version: 11.1.1.7.3.
[ALERT] MAPVIEWER_9023:Cannot load style.
Source: OM.style.StyleStore.parseXMLStyle
OMS: oracle.mapviewer.share.stylex.VariablePieChartStyleModel cannot be cast to oracle.mapviewer.share.stylex.BucketStyleModel
In Mapbuilder, I have a geometry theme with rendering style, an advanced variable pie with variable range, style. This is the XML of advanced style:
<?xml version="1.0" ?>
<AdvancedStyle>
<VariablePieChartStyle startradius="5" increment="4">
<PieSlice name="T004_2009" color="#0033FF"/>
<PieSlice name="T004_2010" color="#FF0033"/>
<PieSlice name="T004_2011" color="#33FF00"/>
<Buckets>
<RangedBucket seq="0" label="0 - 20%" low="0" high="100000"/>
<RangedBucket seq="1" label="20 - 40%" low="100001" high="370000"/>
<RangedBucket seq="2" label="40 - 60%" low="370001" high="1000000"/>
<RangedBucket seq="3" label="60 - 80%" low="1000001" high="2500000"/>
<RangedBucket seq="4" label="80 - 100%" low="2500001" high="2.0E7"/>
</Buckets>
</VariablePieChartStyle>
</AdvancedStyle>
and this is the XML of the theme:
<?xml version="1.0" standalone="yes"?>
<styling_rules key_column="ID" caching="NONE">
<hidden_info>
<field column="INSTITUTION1" name="Port Name"/>
<field column="T004_2009_CHAR" name="2009"/>
<field column="T004_2010_CHAR" name="2010"/>
<field column="T004_2011_CHAR" name="2011"/>
<field column="T004_2012_CHAR" name="2012"/>
<field column="T004_2013_CHAR" name="2013"/>
<field column="T004_2014_CHAR" name="2014"/>
</hidden_info>
<rule column="PASSENGERS_2009,PASSENGERS_2010,PASSENGERS_2011">
<features style="V.T004_PASSENGERS_VPIE"> (NVL(PASSENGERS_2009, 0) !=0 AND NVL(PASSENGERS_2010,0) != 0 AND NVL(PASSENGERS_2011, 0) != 0) </features>
<label column="INSTITUTION1" style="T.CITY_NAME_H"> 1 </label>
</rule>
</styling_rules>
When I preview the theme in mapbuilder everything seems fine.
The problem arises, when I try to add a layer with this theme and style in my map in my APEX (version:4.2.6) application.
This is the javascript:
layer = new OM.layer.VectorLayer("layer1",
def:{
type:OM.layer.VectorLayer.TYPE_PREDEFINED,
dataSource:ds, theme:themename,
url: baseURL
map.addLayer(layer) ;
and this is the error I get:
[ALERT] MAPVIEWER_9023:Cannot load style.
Source: OM.style.StyleStore.parseXMLStyle
OMS: oracle.mapviewer.share.stylex.VariablePieChartStyleModel cannot be cast to oracle.mapviewer.share.stylex.BucketStyleModel
I' d appreciate any help.
Thanks in advance,
VassoHi,
You're setting XML data in a JSON model, that's why the binding is incorrect.
Depending on what your MII transaction is returning, you need to either retrieve the JSON part in the XML, or use a XML Model.
Regards,
Tanguy -
Error with define substitution variable in SQL
Hi there,
I am using PL/SQL developer and trying to define a substitution variable as follows:
define freq = 'Weekly'
Then later on, in my SQL statement, I used this variable in WHERE statement as follows:
WHERE ... (&freq = 'Weekly') and ...
But I got the "ORA-00904: "WEEKLY": invalid identifier" error.
Where is the problem?
Thanks in advance!I don't know about PL/SQL developer but in sqlplus you need single quotes around the variable.
SQL> define freq = 'Weekly'
SQL> select null from dual
2 where &freq = 'Weekly';
old 2: where &freq = 'Weekly'
new 2: where Weekly = 'Weekly'
where Weekly = 'Weekly'
ERROR at line 2:
ORA-00904: "WEEKLY": invalid identifier
SQL> edi
Wrote file afiedt.sql
1 select null from dual
2* where '&freq' = 'Weekly'
SQL> /
old 2: where '&freq' = 'Weekly'
new 2: where 'Weekly' = 'Weekly'
N
SQL> -
Hi
I wrote a program that is supposed to call a method that returns 21 numbers with doubles from the user, then the program is supposed to call a method that displays the highest and lowest numbers entered as well as the average of the numbers. But... I get 2 errors that say cannot resolve symbol for lines 17 and 18 (which is this part number(arrays) and display(arrays) and another one that says cannot resolve symbols for line 40 int average = numbers.getAverage(); heres the program
import javax.swing.JOptionPane;
import java.util.*;
public class array
public static void main (String [] args)
number(arrays);
display(arrays);
int[] numbers = new int[21];
public static double number(int[] numbers)
for(int i = 0; i < numbers.length; i++)
numbers[i] = Integer.parseInt(JOptionPane.showInputDialog("Choose a number"));
public static double display(int[] numbers)
Arrays.sort(numbers);
System.out.println(numbers[0] + "is your lowest number");
System.out.println(numbers[21] + "is your highest number");
int average = numbers.getAverage();
System.exit(0);
}thanksyou loop through and assign the numbers in numbers to
a variable called sum then divide by numbers.length,
would that be how you do it?It might just be a case of sloppy wording, but as written, no, that's not quite what you'd want to do.
for (...) {
sum = numbers[ix];
} That's what your wording says to me. That may not be what you meant, but if it is, try it and see what happens. -
Errors with variable declarations
Hi,
Is it possible that when I declare a variable using the scriplet tags:
<% String test; %>
That it is not being declared properly and I cannot use it later on in the page?
<% test="Hello"; %>
I keep getting error messages and they seem to be centered around some of my variables that have been declared with scriptlet tags.
Thanks,
PreetiInstead of
<% String test; %>
use
<%! String test; %>
Then test will be accessible throughout instead of just the service method.
If the problem persists just post your code & specify the exact error.
null
Maybe you are looking for
-
My Apple AV composite cable no longer works with my 3G iPhone. Anyone else?
I purchased an Apple composite AV cable from my local Apple store shortly after I bought my 3G iPhone. It worked then. I haven't used it much, but this morning I tried it again. This time I got a message something like this: "This accessory was not m
-
Linkage Error in Mapping and Operation mapping testing for Synchronous in NWDS
Dear Experts, Hope you all are doing fine.. I am working in a synchronous scenario Proxy via SAP PI 7.4 to JAVA Application supporting JSON.I wrote JAVA program to convert JSON to XML and while performing test for the JAVA mapping in response structu
-
I damaged my iPhone 4. I have ordered a new 4s. I never backed up or synced my contacts onto my sim card. Do you have to do that manually or will my contacts be on my phone when I put my sim card in the new iPhone 4s? (Will I be able to put my 4
-
A Loan is entered for the employee. While running payroll following error received. Error with a loan wage type A loan wage type in table RT should be deducted, however the remaining net amount was too small Wage type 9SLD Please lower the loan
-
How to update task status from custom task in state machine workflow
i m using custom task for state machine workflow i am using if(this.onTaskChangedSupervisorAction_AfterProperties.ExtendedProperties["Workflowstatus"].ToString().Contains("Approved")) if above is true moving forward its working fine but i want to upd