Updating Charts using XML
Dear All,
I am new to Flex and have to create a desktop application
using Flex 3.0. I want to show mutiple charts and update them
externally using XML. Please suggest how should i go ahead. I don't
want server connectivity as this is desktop application.
Hi,
I have already found the problem.
The problem is not in the ODP.NET.
The problem is that the row is already locked as shown in V$LOCKED_OBJECT
Now the question is, how do I in future know that somebody else has modified and the object status is in locked.
This is because now if it is in locked mode, it does not return any error but just hang there.
The process is not completed even though it is more than 1/2 an hour and i have killed it.
Thanks in advance.
Similar Messages
-
Updating Items in a form using XML
Hello all,
I have a form loaded in SBO. In some conditions I want to disable some items like EditTexts, CheckBoxes, ComboBoxes in the form. Some times I have to enable them.. Since there are more controls in the form I would like to use an XML for doing this.
But when I tried an XML, it did not work for the Enabled property. But it is working for Visible Property.
Do anybody know how to update the XML so that it will work fine?
This is the sample XML used for this purpose.
<?xml version="1.0" encoding="UTF-16" ?>
<Application>
<forms>
<action type="update">
<form FormType="MYFORM" uid="MYFORM_1">
<items>
<action type="update">
<item uid="cmbSlsPr" type="113" left="125" enabled="0" visible="1" />
<item uid="txtCustRef" type="16" left="125" enabled="0" visible="1" />
</action>
</items>
</form>
</action>
</forms>
</Application>
Thanks in advance.
Anoop
Edited by: Anoop Krishnan on Aug 8, 2009 12:43 PMHi Anoop,
Yes, I update forms using XML.
<?xml version="1.0" encoding="UTF-16" ?>
<Application>
<forms>
<action type="update">
<form FormType="133" uid="">
<datasources>
<userdatasources>
<action type="add">
<datasource uid="DSItemUID" type="9" size="100"></datasource>
<datasource uid="DSDocNum" type="0"></datasource>
</action>
</userdatasources>
</datasources>
<items>
<action type="update">
<item uid="FldEDI" type="99" left="384" tab_order="0" width="64" top="98" height="19" visible="1" enabled="1" from_pane="0" to_pane="0" disp_desc="0" right_just="0" description="" linkto="" forecolor="-1" backcolor="-1" text_style="0" font_size="-1" supp_zeros="0" AffectsFormMode="0">
<AutoManagedAttribute></AutoManagedAttribute>
<specific caption="EDI" AffectsFormMode="0" val_on="8" val_off="0">
<databind databound="1" table="" alias="SYS_208"></databind>
</specific>
</item>
<item uid="FldOther" type="99" left="448" tab_order="0" width="74" top="98" height="19" visible="1" enabled="1" from_pane="0" to_pane="0" disp_desc="0" right_just="0" description="" linkto="" forecolor="-1" backcolor="-1" text_style="0" font_size="-1" supp_zeros="0" AffectsFormMode="0">
<AutoManagedAttribute></AutoManagedAttribute>
<specific caption="Outra Info." AffectsFormMode="0" val_on="2" val_off="0">
<databind databound="1" table="" alias="SYS_208"></databind>
</specific>
</item>
<item uid="ExportEDI" type="4" left="300" tab_order="0" width="80" top="150" height="20" visible="1" enabled="1" from_pane="8" to_pane="8" disp_desc="0" right_just="0" description="" linkto="rtgEDI" forecolor="-1" backcolor="-1" text_style="0" font_size="-1" supp_zeros="0" AffectsFormMode="1">
<AutoManagedAttribute></AutoManagedAttribute>
<specific caption="Exportar EDI"></specific>
</item>
Regards,
Vítor Vieira -
Update Database Through XML file using SAP B1 business objects
Hello everyone,
I am facing a problem ie I am not able to update the Database(SQL 2000) through an XML file.
Though i am able to insert the data in the databse using xml file but unable to update that data.
The tables i want to update are OITM,ITM1,OITW. While i was trying to update the Databse i was getting an error ie " -1107 Object's key is not set".
I dont want to use DTW for importing or anything.
Kindly help me out why i am facing this problem asap...Hi Pranay,
My case was that I wanted to replicate an item from one company to another (I guess that's your case also). What I finally did is copy field by field the objects I needed. Later I've find out the solution given here,
Copy items between databases
but I haven't try it out. I expect your comments about it :).
Regards,
Ian -
Error while trying to update the XML template using XML Publisher Administrator
Hello Folks,
We are on R12.1.3
I changed a condition in a report and trying to upload the new XML template using XML Publisher Administrator.
when i click the Apply button, it is throwing an error 'Bad Request'
Navigation : XML Publisher Administrator > Data Definitions > query the report
Click on the name of the report > click 'Update file' besides Data Template > Choose file > Click Apply
I am getting the below error
Bad Request
Your browser sent a request that this server could not understand.
Now, i could not upload a new XML template.
Am I doing anything wrong.
regards,
Krisuser10163762 wrote:
Thank you Eugen and Hussein.
The problem is not with the template.
It seems to be a problem in that particular instance.
Uploaded it in a different instance.
However once i run the program, i cannot view the output as the browser window flashes and disappears.
My colleague says , it is to do with the trusted site to download something from the browser.
Can you please guide me on how to fix this ?
http://bit.ly/1k8e2vi
Thanks,
Hussein -
Update a system form using XML
Hi all,
I'm trying to update a system form by adding a tab (folder). The form is Customer Equipment Card (nb 60150), in the service menu.
I just want to add a folder called Counter.
When I load the XML file below, I get the following error :
System.Runtime.InteropServices.COMException (0xFFFFFFFE): Function not supported on current SBO Version - upgrade is required
If I want to add a button, it's working, but not a folder.
Something's false in this XML file (I add the good uid before I load it) ?
Thanks for your help
Sébastien> - Drop the datasource section
> The error is gone, but I don't see the folder in
> in the form
You could try and check wether it's there but invisible (access it in your code and wait for an exception).
> - Linkto Objet
> If you look at the XML code of the form, you can
> can see that all the folder are links to this item.
> Moreover, when I add the form using VB (it's working
> that way), the XML result will show linkto = "54"
I believe. I analyzed another system form and my own forms: None of the tabs are linked to anything. Is this documented? What does it mean?
> - the data source is SYS_71 for all the folder of the
> form. I don't understand what you mean when you want
> me to set the val_on to this datasource
I looked at the XML source of another system form and the tabs had val_on="SYS_whatever". With my own forms I set val_off="N" and val_on="Y". I remember having had some problems there, but I can't put my finger on it now.
> - item group
> I'm using SBO 6.5, I can't find help on that, maybe
> it's only on 2004.
No, it's 6.5. It's not in the documentation but you will find it somewhere inside the guts of this forum. As I said, I once had trouble adding tabs cleanly to a custom form using XML.
Of course, all this is just blindly stabbing into the dark. What else can we do? -
Revision: 3037
Author: [email protected]
Date: 2008-08-29 06:54:15 -0700 (Fri, 29 Aug 2008)
Log Message:
Update flex-config.xml files used by the team and qa webapps to use the {targetPlayerMajorVersion} token instead of a hardcoded player version in the library-path and external-library-path. This will allow the correct playerglobal.swc to be located when the target player version is set in the flex-config.xml or passed to mxmlc or compc.
Modified Paths:
blazeds/trunk/apps/team/WEB-INF/flex/flex-config.xml
blazeds/trunk/qa/resources/config/flex-config.xmlUnfortunately I don't have the
"org.eclipse.swt.win32.win32.x86_3.1.2.jar" file. On my computer
the folder is not set up the same way (C:\Program Files\Adobe\Flex
Builder 2\plugins) instead it is set up as (C:\Program
Files\Adobe\Flex Builder 2\metadata\plugins) but I've looked in
everything and that file just isn't in there. I've re downloaded it
twice. Still not there. Is there anything else i can do. -
Database updation using XML and stored Procedure?
Hello,
I want to perform updation in multiple tables using XML files.Please suggest can I do updation using xml and stored procedure.
If yes then which is more efficient and takes less time.
1.Updation using xml files only
2.Updation using xml files with stored procedure.
3.Stored procedure alone.
If direct xml and stored procedure communication is possible.then please write how.
Thanks in advance for any help.Here's a sample. The next code drop of the XSQL Servlet will make the easy-to-do from within XSQL Pages:
package package1;
import org.w3c.dom.*;
import java.sql.*;
import oracle.jdbc.driver.*;
import oracle.xml.sql.query.OracleXMLQuery;
public class Class1 extends Object {
public static void main( String[] arg ) throws Exception {
Connection conn = getConnection();
CallableStatement ocs = conn.prepareCall("begin ? := App.HotItems('PAUL'); end;");
ocs.registerOutParameter(1,OracleTypes.CURSOR);
ocs.execute();
ResultSet rs = ((OracleCallableStatement)ocs).getCursor(1);
OracleXMLQuery oxq = new OracleXMLQuery(conn,rs);
System.out.println(oxq.getXMLString());
oxq.close();
rs.close();
ocs.close();
conn.close();
public static Connection getConnection() throws Exception {
String username = "scott";
String password = "tiger";
String dburl = "jdbc:oracle:thin:@localhost:1521:xml";
String driverClass = "oracle.jdbc.driver.OracleDriver";
Driver d = (Driver)Class.forName(driverClass).newInstance();
return DriverManager.getConnection(dburl,username,password);
null -
Dynamically update swf file in sharepoint using xml data
Hi,
I need some help/enlightenment on how to auto-update the swf file in sharepoint using xml data.
I am encountering an error "Cannot access External Data" and pointing to adobe's Cross-domain policy file extension.
My questions is:
1. Where should the cross-domain file be copied? In the sharepoint webserver's root folder?
Right now, we generate the swf file from xcelsius and manually upload them in the sharepoint. However, we wish to automate the data content of this file.
Thanks for the help.
EmersonGetFileByServerRelativeUrl.... since you're getting a FILE, you'll need a URL to a FILE (not just a library)... by SERVER relative URL, so you'll need to include the site collection path and such, not just the subsite relative URL.
Now working fine....
url: appweburl + "/_api/SP.AppContextSite(@target)/web/ GetFileByServerRelativeUrl('/sites/apps/Shared Documents/test.txt')/CheckOut()?@target='" + hostweburl + "'",
method: "POST",
data: metatdata, -
Update multiple InDesign documents using XML
I am looking for a solution to update multiple files using XML.
We have over 100 resumes in indesign and each resume has about a dozen projects (name, size, cost, location)
I would like to keep all of the projects in a master file "projects.xml" and then basically populate each resume from this file. This would allow me to make one change to a project and have that project update across all the resumes.
This file would be edited and probably rearanged frequently. I have a basic understanding of XML but am not sure how moving the order of projects within the XML file will effect the resumes.
My question is what type of issues would I be faced in working this way and how could I tackle them. Any workflow or advice would be very helpful.
-JustinIn my understanding, the order of different elements in the XML file wouldn't matter - the order is set by the style sheet (XSLT) file.
I can't give any real suggestions though, except to consider a third party plugin which would make any XML solution much easier - XMPie, DesignMerge, StudioID etc. You could then reference a database (Access/Excel/csv) containing columns for name, project1, project2... and set the project info to only display if there is a corresponding entry in the database file. -
C# Example: Update existing form using XML
I am searching for an C# example to manipulate existing forms using XML. The result I want to achieve is to add a button on the Item form (10003).
It must be possible. Look for a discussing about this topic at Re: Update a system form with XML: empty screen when this is a target docum for example.
The main steps are:
1. Get XML system form
2. Replace UID
3. Update the system form using XML
4. Load 'new' form.
The problem is that I don't have a good example how to 'Get' and 'Load' the XML using C# in Visual Studio 2005. It is a little bit frustrating, because I can't get the whole picture...
Do you still think it is better to load a new form instead of changing the original? -
Using XML to update objects in DIAPI
I've been testing out the XML capabilities of DIAPI and have hit a road block. When I run the following code I get an error that I can't update the address field even though I'm not actually changing the address field. When I look at the xml and compare it to the 'order.Address' value, I notice that the 'ReadXML()' call actually changes the line breaks in the address from '\r' to '\n' and I'm guessing this is what flags it as changed. Even if I remove the address fields from the XML, I move on to another failure of the DocRate field with the same error. If I remove this one from the XML the error doesn't go away. The end result is that I can't find a way to use XML to update existing documents. Any ideas?
<b>Sample code</b>
company.XmlExportType = BoXmlExportTypes.xet_ExportImportMode;
Documents order = (Documents)company.GetBusinessObject(BoObjectTypes.oOrders);
order.GetByKey(1);
string startingXML = order.GetAsXML();
StringReader sr = new StringReader(startingXML);
XmlTextReader reader = new XmlTextReader(sr);
XmlDocument doc = new XmlDocument();
doc.Load(reader);
reader.Close();
XmlElement root = doc.DocumentElement;
XmlElement busPartElement = (XmlElement)root.SelectSingleNode("/BOM/BO/Documents/row/Comments");
busPartElement.InnerText += "test";
string updatedXML = doc.OuterXml;
//company.StartTransaction();
company.XMLAsString = true;
Documents updateOrder = (Documents)company.GetBusinessObject(BoObjectTypes.oOrders);
updateOrder.GetByKey(1);
updateOrder.Browser.ReadXml(updatedXML, 0);
string comment = updateOrder.Comments;
updateOrder.DocRate = 0;
if (updateOrder.Update() != 0)
int ErrCode = 0;
string ErrMessage = string.Empty;
company.GetLastError(out ErrCode, out ErrMessage);
System.Runtime.InteropServices.Marshal.ReleaseComObject(company);
throw new Exception(ErrCode.ToString() + " - " + ErrMessage);
//company.EndTransaction(BoWfTransOpt.wf_Commit);
<b>Error</b>
System.Exception : -1029 - [ORDR.DocNum] , 'Field cannot be updated (ODBC -1029)'
When the following code is added the same error occurs with DocRate
XmlNode row = root.SelectSingleNode("/BOM/BO/Documents/row");
XmlNode childNode = root.SelectSingleNode("/BOM/BO/Documents/row/Address");
row.RemoveChild(childNode);
childNode = root.SelectSingleNode("/BOM/BO/Documents/row/Address2");
row.RemoveChild(childNode);
Adding the following doesn't make the error on 'DocRate' go away
childNode = root.SelectSingleNode("/BOM/BO/Documents/row/DocRate");
row.RemoveChild(childNode);Hello.
In this line:
updateOrder.GetByKey(1);
You are getting order from base by Entry = 1, then You are trying to write there from XML other order.
In XML the DocEntry and DocNum (mandatory) are the same like in base ?
Maybe this is the problem.
Please check this.
Sorry for my English.
Hope this helps.
Regards
Kamil Wydra -
How can i develop charts using only xml defination
how can i develop charts using only xml defination.can any one please let me know
mankshello,
in reports 6i the charts are created using oracle graphics which stores the chart definitions in a separate file (.OGD). there is not XML interface for graphics.
with reports 9i and the introduction of the BIgraphBean the definition of the chart-properties is also done in XML.
reports 9i will be available with iAS Release 2.
regards,
the oracle reports team -
How Do You Use XML To Create Image Upload On A WebSite?
Hello,
Could some one please help me understand how to create web image gallery and web video gallery using XML? I have found few xml codes that could be used to do this but I am not so sure how to use them. I want my clients to be able upload images and videos with linking thumbnails to Image and or Videos. Do you think the codes I included in this question will help me achive this goal? And do I need to put all in one and in the same directory so it will work? Please help with your idea and tell me how you would use these codes and how you may step-by-step implement the idea your self to your own web site.
I have also included the instruction I found on the web with the codes.
Starting with You Tube, API on their video gallery, here are the codes I found,
Assume you are to use the YouTube, XML code; What will you change here so it will work on your own www.domain.com?
<% Dim xml, xhr, ns, YouTubeID, TrimmedID, GetJpeg, GetJpeg2, GetJpeg3, thumbnailUrl, xmlList, nodeList, TrimmedThumbnailUrl Set xml = Server.CreateObject("MSXML2.FreeThreadedDOMDocument")
xml.async = False
xml.setProperty "ServerHTTPRequest", True
xml.Load("http://gdata.youtube.com/feeds/api/users/Shuggy23/favorites?orderby=updated") If xml.parseError.errorCode <> 0 Then
Response.Write xml.parseError.reason End If Set xmlList = xml.getElementsByTagName("entry") Set nodeList = xml.SelectNodes("//media:thumbnail") For Each xmlItem In xmlList
YouTubeID = xmlItem.getElementsByTagName("id")(0).Text
TrimmedID = Replace(YouTubeID, "http://gdata.youtube.com/feeds/api/videos/", "")
For Each xmlItem2 In nodeList
thumbnailUrl = xmlItem2.getAttribute("url")
Response.Write thumbnailUrl & "<br />"
Next Next
%>
For the image gallery, the following are the codes I found with your experience do I need to use the entire codes or just some of them that I should use?
CODE #01Converting Database queries to XML
Using XML as data sources presumes the existence of XML. Often, it is easier to have the server create the XML from a database on the fly. Below are some scripts for common server models that do such a thing.
These are starting points. They will need to be customized for your particular scenario.
All these scripts will export the data from a database table with this structure:
ID: integer, primary key, autoincrement
AlbumName: text(255)
ImagePath: text(255)
ImageDescription: text(2000)
UploadDate: datetime
The output of the manual scripts will look like:
<?xml version="1.0" encoding="utf-8" ?>
<images>
<image>
<ID>1</ID>
<album><![CDATA[ Family ]]></album>
<path><![CDATA[ /family/us.jpg ]]></path>
<description><![CDATA[ here goes the description ]]></description>
<date><![CDATA[ 2006-11-20 10:20:00 ]]></date>
</image>
<image>
<ID>2</ID>
<album><![CDATA[ Work ]]></album>
<path><![CDATA[ /work/coleagues.jpg ]]></path>
<description><![CDATA[ here goes the description ]]></description>
<date><![CDATA[ 2006-11-21 12:34:00 ]]></date>
</image>
</images>
These are all wrapped in CDATA because it is will work with all data types. They can be removed if you know you don't want them.
Note: If using the column auto-generating versions, ensure that all the column types are text. Some databases have data type options like 'binary', that can't be converted to text. This will cause the script to fail.
CODE #02ASP Manual: This version loops over a query. Edit the Query and XML node names to match your needs.
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<%
Dim MM_conn_STRING
MM_conn_STRING = "dsn=image_gallery;uid=xxxx;pwd=xxxx"
%>
<%
Dim rsImages
Dim rsImages_cmd
Dim rsImages_numRows
' Query the database and get all the records from the Images table
Set rsImages_cmd = Server.CreateObject ("ADODB.Command")
rsImages_cmd.ActiveConnection = MM_conn_STRING
rsImages_cmd.CommandText = "SELECT ID, AlbumName, ImagePath, ImageDescription, UploadDate FROM images"
rsImages_cmd.Prepared = true
Set rsImages = rsImages_cmd.Execute
' Send the headers
Response.ContentType = "text/xml"
Response.AddHeader "Pragma", "public"
Response.AddHeader "Cache-control", "private"
Response.AddHeader "Expires", "-1"
%><?xml version="1.0" encoding="utf-8"?>
<images>
<% While (NOT rsImages.EOF) %>
<image>
<ID><%=(rsImages.Fields.Item("ID").Value)%></ID>
<album><![CDATA[<%=(rsImages.Fields.Item("AlbumName").Value)%>]]></album>
<path><![CDATA[<%=(rsImages.Fields.Item("ImagePath").Value)%>]]></path>
<description><![CDATA[<%=(rsImages.Fields.Item("ImageDescription").Value)%>]]></description>
<date><![CDATA[<%=(rsImages.Fields.Item("UploadDate").Value)%>]]></date>
</image>
<%
rsImages.MoveNext()
Wend
%>
</images>
<%
rsImages.Close()
Set rsImages = Nothing
%>
CODE #03
Automatic: This version evaluates the query and automatically builds the nodes from the column names.
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<%
Dim MM_conn_STRING
MM_conn_STRING = "dsn=image_gallery;uid=xxxx;pwd=xxxx"
%>
<%
Dim rsAll
Dim rsAll_cmd
Dim rsAll_numRows
' Query the database and get all the records from the Images table
Set rsAll_cmd = Server.CreateObject ("ADODB.Command")
rsAll_cmd.ActiveConnection = MM_conn_STRING
rsAll_cmd.CommandText = "SELECT * FROM Images"
rsAll_cmd.Prepared = true
Set rsAll = rsAll_cmd.Execute
' Send the headers
Response.ContentType = "text/xml"
Response.AddHeader "Pragma", "public"
Response.AddHeader "Cache-control", "private"
Response.AddHeader "Expires", "-1"
%><?xml version="1.0" encoding="utf-8"?>
<root>
<% While (NOT rsAll.EOF) %>
<row>
<%
For each field in rsAll.Fields
column = field.name
%>
<<%=column%>><![CDATA[<%=(rsAll.Fields.Item(column).Value)%>]]></<%=column%>>
<%
Next
%>
</row>
<%
rsAll.MoveNext()
Wend
%>
</root>
<%
rsAll.Close()
Set rsAll = Nothing
%>OK, I understand - thanks for that.
I thought the whole process was supposed to be a bit more seemless? Having to upload/download documents and manually keep them in sync will leave a lot of room for errors.
It's kinda painful the way iOS doesn't have folders. It makes things incompatible with the Mac and means you can't group files from multiple apps into a single project - who organises their digital life by the apps they use?
I think I'll recommend they use their iPad only.
Thanks for that.
Cheers
Ben -
Pareto Chart using Report Generation Tool kit
Hi,
Please help me to get clarification for the following:
I need to log data into MS Excel Report and generate Pareto Chart using LabVIEW for the Logged data.
I have Report Generation Tool kit. but i couldnt find the an option to generate Pareto chart with it.
Thanks,
Thirumala.One way is to Create a Excel template in the predefined format with the rows/colums linked for the Chart.
Use this template with report generation toolkit to populate data in the predefined cells.Based on that the chart will be automatically updated. -
We have an update query recently brought to my attention that is running extremely slow on Oracle 11.2.0.1 against a secure file binary XML table using
update /*+ NO_XML_DML_REWRITE */croutreach.action set object_value = :1 where actn_id = :2 .
I am told the majority/near majority of the ~ 16 fields are updated. Also this table has numerous predefined virtual columns with fn based indexes on them.
My first inclination was to recast this using the Oracle updatexml function. I was told, the /*+ NO_XML_DML_REWRITE */ hint would also be necessary here.
update /*+ NO_XML_DML_REWRITE */
<tble_name> a
set a.object_value = updatexml(a.object_value ...).
Last year our dba's were instructed by Oracle Support to use this hint, as the update wasn't updating any records w.o any error msgs.
+1. Hoping to find out if anyone has run across using this hint in some capacity and what was their experience?+
In trying to optimizie this update statement, I'll start from scratch not using the /*+ NO_XML_DML_REWRITE */ hint and will commence with using the updatexml function with setting up an xmlindex.
+2. Hoping to receive some suggestions on creating the proper xmlindex - figuring an unstructured index. If get some good performance with the xmlindex; hoping to retire some of the virtual column usage.+
+3. Any suggestions on living with virtual columns in conjunction with xmlindexes? See the action table definition and associated ivirtual columns and indexes. This table seems over indexed...+
REATE
TABLE "CROUTREACH"."ACTION" OF XMLTYPE
CONSTRAINT "ACTN_ID_PK" PRIMARY KEY ("ACTN_ID") USING INDEX PCTFREE 10
INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE(INITIAL 65536 NEXT
1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1
FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE
DEFAULT) TABLESPACE "ACME_DATA" ENABLE
XMLTYPE STORE AS SECUREFILE BINARY XML
TABLESPACE "ACME_DATA" ENABLE STORAGE IN ROW CHUNK 8192 CACHE READS LOGGING
NOCOMPRESS KEEP_DUPLICATES STORAGE(INITIAL 106496 NEXT 1048576 MINEXTENTS 1
MAXEXTENTS 2147483645 PCTINCREASE 0 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT)
ALLOW NONSCHEMA ALLOW ANYSCHEMA VIRTUAL COLUMNS
*"ACTION_DEF_URN"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/srvContextPointer/outreachActionDefInfo/@actionDefUrn
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"STAT_DT"* AS (SYS_EXTRACT_UTC(CAST(TO_TIMESTAMP_TZ(SYS_XQ_UPKXML2SQL(
SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/@status_dt'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2),'SYYYY-MM-DD"T"HH24:MI:SS.FFTZH:TZM') AS TIMESTAMP
WITH
TIME ZONE))),
*"ACT_DEF_ID"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/srvContextPointer/outreachActionDefInfo/@actionDefId'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(20))),
*"CORRL_ID"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/correlationId'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"STAT_RSN"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/statusReason'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(30))),
*"ACT_APPNT_DT"* AS (SYS_EXTRACT_UTC(CAST(TO_TIMESTAMP_TZ(SYS_XQ_UPKXML2SQL(
SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/actionAppointment/appointment_dt'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2),'SYYYY-MM-DD"T"HH24:MI:SS.FFTZH:TZM') AS TIMESTAMP
WITH
TIME ZONE))),
*"UPDT_DT"* AS (SYS_EXTRACT_UTC(CAST(TO_TIMESTAMP_TZ(SYS_XQ_UPKXML2SQL(
SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/@update_dt'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2),'SYYYY-MM-DD"T"HH24:MI:SS.FFTZH:TZM') AS TIMESTAMP
WITH
TIME ZONE))),
*"CRET_DT"* AS (SYS_EXTRACT_UTC(CAST(TO_TIMESTAMP_TZ(SYS_XQ_UPKXML2SQL(
SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/@create_dt'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2),'SYYYY-MM-DD"T"HH24:MI:SS.FFTZH:TZM') AS TIMESTAMP
WITH
TIME ZONE))),
*"ACT_SEQ"* AS (CAST(TO_NUMBER(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/srvContextPointer/outreachActionDefInfo/@sequence'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2)) AS NUMBER(10))),
*"SERVICE_DEF_URN"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03";
/action/srvContextPointer/serviceDefUrn'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(100))),
*"ASSIGN_TEAM_CD"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/assignment/@teamCategoryCode'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"ASSIGN_STAFF_ID"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
/action/assignment/staffProfileId'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"ACTION_TYPE"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03"; (::)
declare namespace xsi="http://www.w3.org/2001/XMLSchema-instance"; (::)
local-name-from-QName(QName("http://www.cigna.com/acme/domains/actions/2010/03",/action/@xsi:type))
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"ACTN_ID"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03";/action/@id'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50))),
*"STATUS"*AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03";/action/@status'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(20))),
*"ACME_MBR_ID"* AS (CAST(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(XMLQUERY(
'declare default element namespace "http://www.cigna.com/acme/domains/actions/2010/03";/action/acmeMemberId'
PASSING BY VALUE SYS_MAKEXML(128,"XMLDATA") RETURNING CONTENT ),0,0,
16777216,0),50,1,2) AS VARCHAR2(50)))
PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0
FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE UNIQUE INDEX *"CROUTREACH"."SYS_C0014547"* ON "CROUTREACH"."ACTION"
"SYS_NC_OID$"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0
FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE UNIQUE INDEX *"CROUTREACH"."SYS_IL0000082156C00003$$"* ON "CROUTREACH".
"ACTION"
PCTFREE 10 INITRANS 2 MAXTRANS 255 STORAGE(INITIAL 65536 NEXT 1048576
MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST
GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
TABLESPACE "ACME_DATA" PARALLEL (DEGREE 0 INSTANCES 0) ;
CREATE UNIQUE INDEX *"CROUTREACH"."ACTN_ID_PK"* ON "CROUTREACH"."ACTION" (
"ACTN_ID") PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE(
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0
FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT) TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_STAT_RSN_IDX"* ON "CROUTREACH"."ACTION"
"STAT_RSN"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_UPDT_DT_IDX"* ON "CROUTREACH"."ACTION"
"UPDT_DT"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_CRET_DT_IDX"* ON "CROUTREACH"."ACTION"
"CRET_DT"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_STAT_DT_IDX"* ON "CROUTREACH"."ACTION"
"STAT_DT"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_MBRID_TYP_STAT_IDX"* ON "CROUTREACH"."ACTION"
"ACME_MBR_ID",
"ACTION_TYPE",
"STATUS"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACT_ACTDEF_URN_IDX"* ON "CROUTREACH"."ACTION"
"ACTION_DEF_URN"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;
CREATE
INDEX *"CROUTREACH"."ACTION_ACT_DEF_ID_STATUS_IDX"* ON "CROUTREACH"."ACTION"
"ACT_DEF_ID",
"STATUS"
PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS STORAGE
INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE
0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
TABLESPACE "ACME_DATA" ;Any suggestions much appreciated.
Regards,
Richard Blanchardodie 63
update /*+ NO_XML_DML_REWRITE */croutreach.action set object_value = :1 where actn_id = :2 .
This update pattern is used in the production environment and is slowing the environment down as more xml content is increased. In a new release build, this update pattern against the action table described earlier, is particularly problematic.
Have some more information on the /*+ NO_XML_DML_REWRITE */ hint. It turns out, last year, updates statements would intermittently fail to correctly update silently failing. An Oracle Service Request was created. Over the span of about 5 mnths, Oracle determined a very low level Oracle kernel bug was the culprit. Oracle As a result of this SR, Oracle SUpport created BUG 11939507 <ORA-08102: index key not found during update on xmltable with a virtual column>. This bug is viewable on metalink. Oracle claims this bug has only been oberved on In the interim to 11.2.0.3, Oracle Support mentioned to use /*+ NO_XML_DML_REWRITE */; thus disabling piecewise update.
Here's preface information on this bug:
Bug 11939507: ORA-08102: INDEX KEY NOT FOUND DURING UPDATE ON XMLTABLE WITH VIRTUAL COLUMN
Bug Attributes
Type B - Defect Fixed in Product Version 12.1
Severity 2 - Severe Loss of Service Product Version 11.2.0.1
Status 80 - Development to Q/A Platform 23 - Oracle Solaris on SPARC (64-bit)
Created 30-Mar-2011 Platform Version 10
Updated 13-Feb-2012 Base Bug -
Database Version 11.2.0.1
Affects Platforms Generic
Product Source Oracle
Hdr: 11939507 11.2.0.1 XDB 11.2.0.1 BINARY PRODID-5 PORTID-23
Abstract: ORA-8102: INDEX KEY NOT FOUND DURING UPDATE ON XMLTABLE WITH VIRTUAL COLUMN*** 03/30/11 12:22 pm ***
BUG TYPE CHOSEN =============== code
Component: XML Database =======================
DETAILED PROBLEM DESCRIPTION ============================
The issue happens intermittently when running a batch program with 50 concurrent sessions that involves high concurrent updates.
DIAGNOSTIC ANALYSIS =================== reproducible testcase on customer dummy data reproduced by Thomas.
WORKAROUND? =========== No
TECHNICAL IMPACT ================ Customer is experiencing this error which is critical to the application because it causes a home health care provider to possibly lose a couple hours worth of work and have to start from scratch. The condition has only accessed concurrently from about 40 threads
RELATED ISSUES (bugs, forums, RFAs) =================================== Bug 8514561 - ORA-8102 WHEN UPDATING TABLE
HOW OFTEN DOES THE ISSUE REPRODUCE AT CUSTOMER SITE? ==================================================== Intermittent
DOES THE ISSUE REPRODUCE INTERNALLY? ==================================== Intermittent
IS A TESTCASE AVAILABLE? ======================== Yes The good news is, this bug is corrupting a virtual index column.
I'll try test cases using the update pattern; 'update /*+ NO_XML_DML_REWRITE */croutreach.action set object_value = :1 where actn_id = :2 ' - substituting actual values for the bind variables and removing interfering virtual columns. Wil lcompare with and w/o the hint.
This wil address your; "Where does the new values come from? Individual variables?" - and provide sample data.
Presently, this update pattern is used 'blindly' in that when no xml relevent changes are identified, only a couple of the roughly 16 fields are updated - yet the whole document gets updated with this update pattern. When changes occur, the whole document is updated. Will work with updating 1 or 2 fields using updatexml and try the xmlexists function for the predicate.
04/25/12 Update:
odie 63,
Here's a sample xml record from the action securefile binary xml table:
<?xml version = '1.0' encoding = 'UTF-8' standalone = 'yes'?><action xsi:type="AssessmentActionType" status_dt="2012-01-18T19:38:21.077Z" status="not applicable" create_dt="2012-01-17T23:10:16.173Z" id="dfdfdfdfdfddfdfdfdfdfdf" xmlns:ns5="http://www.xxxxx.ddd/exception/definition/schema/2010/01" xmlns="http://www.xxxxxx.ddd/mmm/domains/actions/2010/03" xmlns:ns6="http://www.xxxxx.ddd/mmm/domains/utility/outcome/2010/03" xmlns:ns7="http://www.xxxxxx.ddd/mmm/domains/common/2010/03" xmlns:ns2="http://www.xxxxx.ddd/mmm/messages/actions/2010/03" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://www.xxxxx.ddd/mmm/domains/workforce/2010/03" xmlns:ns4="http://www.xxxxxx.ddd/mmm/domains/entitlement/2011/11">
<acmeMemberId>abcdefghijklmnop</acmeMemberId>
<advocacyPlanId>qrstuvwxyz</advocacyPlanId>
<srvContextPointer>
<serviceDefUrn>urn:coderunner:Medical:Definition:ServiceService:11111:7</serviceDefUrn>
<outreachActionDefInfo sequence="1" actionDefUrn="urn:xxxxxxxxxx:Medical:Definition:Action:50813:2" actionDefId="xxxxxx">
<srvContextPath>Access Profile~Why did you access the profile?~Reason for access?</srvContextPath>
</outreachActionDefInfo>
</srvContextPointer>
</action>Started out using this update statement against the virtual column a.actn_id. This column is also indexed as a fbi.
UPDATE /*+ NO_XML_DML_REWRITE */ action A
SET A.object_value = updatexml(A.object_value,'/action/@status','triggered','xmlns="http://www.xxxx.vvv/yyy/domains/actions/2010/03"')
where a.actn_id='888a80be-d69f-464d-b3f7-85b6209f918e';
This statment updates fine with and w/o the hint. This hint takes away the piecewise update of the xml document and relies upon the a.actn_id virtual column.
Then removed the reliance on the virtual column using the xmlexists fn.
First did an alter index 'actn_id_pk invisible' to take the virtual column out of consideration by the optimizer.
UPDATE /*+ NO_XML_DML_REWRITE */ action A
SET A.object_value = updatexml(A.object_value,'/action/@status','triggered','xmlns="http://www.xxxx.vvv/yyy/domains/actions/2010/03"')
where xmlexists('$p/action[@id="'888a80be-d69f-464d-b3f7-85b6209f918e'"]' PASSING object_value as "p");
This update runs but doesn't update any columns - with or without the hint.
Also created a basic unstructured xmlindex to remove the full table scan - which worked fine execution plan-wise.
create index action_xmlindex_ix on action (object_value) indextype is xdb.xmlindex;Per the SR on this, the /*+ NO_XML_DML_REWRITE */ disables piecewise update and is a workaround for the bug surrounding virtual column index usage when having many concurrent sessions and updates against a table with millions of xml documents. Getting rid of the virtual column in the predicate removes the need for the workaround hint.
My problem is This update runs but doesn't update any columns. Maybe am missing something or doing a syntax/semantic error ?
Any assistance much appreciated...
Regards,
Rick Blanchard
Edited by: RickBlanchardSRSCigna on Apr 25, 2012 12:52 PM
Maybe you are looking for
-
How can I unsplit my mozilla screen? I want to see only one screen at a time!
When I open mozilla only one screen shows up. Then when I open another website from my bookmarks mozilla all of the sudden split the screen into one website and then icloud. Very frustrating. Any help would be appreciated.
-
How To Split Large Excel or CSV Files into Smaller Files
Does anyone know how to split a large Excel or CSV file into multiple smaller files? Or, is there an app that will work with Mac to do that?
-
How to disable a table UI element of Webdynpro for java
Hi friends, I am having the following scenario regarding the table element. I am having two buttons "createTask" and "EditTask" . in taskView when i click the the create button the table should not visble and on click of the EditTask button the ta
-
Update to Firefox 3.6.9 causes website to flicker
After updating Firefox to 3.6.9, the SAS Online Doc web site flashes as if it is being reloaded over and over again. IE does not show this behavior.
-
Odbc driver returned an error (SQLExecDirectW). Error Details Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OB