Applying an XSL using PL/SQL

I've got a question about the XML toolkit.
I want to apply an XSL stylesheet on an XML document internally in the database using PL/SQL.
I've got an application that must work with XML internally but its output must be anything. (CSV, XML, WML etc).
Normally (when using IE 5.x) the stylesheet is applied when the document is parsed. I want to do this internally in the database.
Is this possible? And does anyone have examples of this?
THanks in advance.
Martin Kleinman,
Webdeveloper, Desyde BV, Baarn

Dup post. Posted in AQ forum at {thread:id=1126132}

Similar Messages

  • XML using PL-SQL

    Hi All,
    I am trying to use XML for building an application. Is it
    possible to generate page by only using a PL-SQL?
    I know how to generate XML by using PL-SQL.
    --How can I apply XSL document to it?
    Thanks,
    Samir

    The XML Developers kit available on this site at: http://technet.oracle.com/tech/xml/
    contains utilities for parsing XML with PL/SQL and other methods.

  • Applying multiple xsl's

    I've inheirited someone else's code, as we tend to do from time to time. The simplest way that I can think of fixing a problem with our xml is to apply one style sheet to the xml, then apply a second.
    I have tried multiple times to get this to work, but I have basically no idea what I am doing. I'm no XML guru, by a long shot. If someone could give me an example of applying 2 sheets(1 before the other, so the 2nd transforms the result of the first) using PL/SQL or having one XSL call the other, that would be great.
    I have tried using <xsl:apply-imports> and/or the xslprocessor object to apply 2 sheets, but it seems to just apply the 2nd.
    We use PL/SQL to generate XML from a query stored in a clob, then apply a stylesheet to it and store it back out in the database in clob form.

    I figured out a way to do it, just wondering if this is the right way since I basically just copied code. I've got a good idea, but I'm not 100% sure what it's doing.
    I tried to add all the declerations, if i forgot 1 assume that it was declared properly. There was a bunch of DBMSXML stuff before this section of code, figured it wasn't needed.
    -------------Declerations----------------------
    p_xsl               varchar2--parameter passed in
    v_xsl               varchar2(200);
    v_xmldoc          xmldom.DOMDocument;
    v_stylesheet     xslprocessor.Stylesheet;
    v_stylesheet2     xslprocessor.Stylesheet;
    r_xml      clob;
    ------------Initializations--------------------
    v_parser := xmlparser.newparser;
    xmlparser.setbasedir(v_parser, v_basedir);
    xmlparser.parseClob(v_parser, r_xml);
    v_xmldoc := xmlparser.getDocument(v_parser);
    ------------Apply 1st style sheet---------------
    v_xsl := 'c:\style_sheet2.xsl';
    v_stylesheet2 := xslprocessor.newstylesheet(v_xsl, v_xsl);
    v_xslproc := xslProcessor.newProcessor;
    dbms_lob.trim(r_xml, 0);
    xslprocessor.processXSL(v_xslproc,
                                       v_stylesheet2,
                                       v_xmldoc,
                                       r_xml);
    xmlparser.parseClob(v_parser, r_xml);
    ------------Apply 2nd style sheet---------------
    v_xmldoc := xmlparser.getDocument(v_parser);
    xslProcessor.freeProcessor(v_xslproc);
    v_stylesheet := xslprocessor.newstylesheet(p_xsl, p_xsl);
    v_xslproc := xslProcessor.newProcessor;
    dbms_lob.trim(r_xml, 0);
    xslprocessor.processXSL(v_xslproc,
                                       v_stylesheet,
                                       v_xmldoc,
                                       r_xml);
    xmlparser.parseClob(v_parser, r_xml);
    ------------Free up resources--------------------
    xslProcessor.freeProcessor(v_xslproc);
    xslprocessor.freeStylesheet(v_stylesheet);
    Xslprocessor.freestylesheet(v_stylesheet2);
    xmlparser.freeparser(v_parser);

  • Trying to install WSUS role on Windows Server 2012 R2 using dedicated SQL Instance with static port on remote SQL Server 2012 SP1 CU7 on Windows Server 2012 R2.

    I am trying to install WSUS role on Windows Server 2012 R2 using dedicated SQL Instance with static port on remote SQL Server 2012 SP1 CU7 on Windows Server 2012 R2.
    It verifies the connection and then throws the error:
    The request to add or remove features on the specified server failed. The operation cannot be completed, because the server you specified requires a restart.
    WSUS Server : Windows Server 2012 R2
    Remote SQL Server: 2012 SP1 CU7 hosted on Windows Server 2012 R2
    Please let me know if anyone has experienced this issue.

    We were trying to install WSUS role on Windows Server 2012 R2 using dedicated SQL Instance with static port on remote SQL Server 2012 SP1 CU7 on Windows Server 2012 R2.
    It verifies the connection and then throws the error:
    The request to add or remove features on the specified server failed. The operation cannot be completed, because the server you specified requires a restart.
    Same error even after rebooting the server multiple times.
    WSUS Server : Windows Server Standard2012 R2
    Remote SQL Server: Windows Server 2012 SP1 CU7 hosted on Windows Server 2012 R2
    Event ID 7000:
    The Windows Internal Database service failed to start due to the following error:
    The service did not start due to a logon failure.
    Event ID 7041
    The MSSQL$MICROSOFT##WID service was unable to log on as NT SERVICE\MSSQL$MICROSOFT##WID with the currently configured password due to the following error:
    Logon failure: the user has not been granted the requested logon type at this computer.
    Service: MSSQL$MICROSOFT##WID
    Domain and account: NT SERVICE\MSSQL$MICROSOFT##WID
    This service account does not have the required user right "Log on as a service."
    User Action
    Assign "Log on as a service" to the service account on this computer. You can use Local Security Settings (Secpol.msc) to do this. If this computer is a node in a cluster, check that this user
    right is assigned to the Cluster service account on all nodes in the cluster.
    If you have already assigned this user right to the service account, and the user right appears to be removed, check with your domain administrator to find out if a Group Policy object associated
    with this node might be removing the right.
    I found following article:
    "MSSQL$MICROSOFT##WID service was unable to log on as NT SERVICE\MSSQL$MICROSOFT##WID" error when you install WID in Windows Server 2012
    http://support.microsoft.com/kb/2832204/en-us
    To work around the issue, use one of the following methods:
    Assign the Log on as a service user right to NT SERVICE\ALL SERVICES in the GPO that defines the user right.
    Exclude the computer from the GPO that defines the user right.
    We moved the SCCM server to OU where no policies were getting applied and then applied the new GPO to that OU. Restarted the server and we were able to install WSUS role.
    Regards
    PR

  • Problem using a SQL database Catalogue to insert data to a table

    I am developing with Version:
    10.3.1.0, Build: #99765....
    as part of a step in my process I need to store some data in an audit table.
    I have setup the SQL Catalogue entry and then use the following code:
    sentMail is defined as a local variable
    sentMail = RSPCA.Resources.RSPCA.R_SENTEMAIL()
    sentMail.sentemailBody = sendInternalRequest.htmlbody
    sentMail.sentemailDatesent = Fuego.Lang.Time
    sentMail.sentemailSubject = subject
    sentMail.sentemailTo = creation.participant.email
    sentMail.sentemailType = "People"
    store sentMail
    This works if I comment out this line:
    sentMail.sentemailBody = sendInternalRequest.htmlbody
    The issue I'm having maybe something to do with the size of the data, in oracle the field is a varchar2(4000) and it looks like the catalogue treats it as a String(4000), if I make sure I only put around 1500 characters in the field it works, but as soon as I put all in from my test data (about 2300) it fails with this message:
    The method 'CIL_sendToHQ' from class 'EstablishmentManagement.EMMaintainPeopleProcess.Default_1_0.Instance' could not be successfully executed.
    Caused by: [BEA][Oracle JDBC Driver][Oracle]ORA-01461: can bind a LONG value only for insert into a LONG column
    Caused by: [BEA][Oracle JDBC Driver][Oracle]ORA-01461: can bind a LONG value only for insert into a LONG column
    fuego.lang.ComponentExecutionException: The method 'CIL_sendToHQ' from class 'EstablishmentManagement.EMMaintainPeopleProcess.Default_1_0.Instance' could not be successfully executed.
         at fuego.component.ExecutionThreadContext.invokeMethod(ExecutionThreadContext.java:519)
         at fuego.component.ExecutionThreadContext.invokeMethod(ExecutionThreadContext.java:273)
         at fuego.fengine.FEEngineExecutionContext.invokeMethodAsCil(FEEngineExecutionContext.java:219)
         at fuego.server.execution.EngineExecutionContext.runCil(EngineExecutionContext.java:1278)
         at fuego.server.execution.microactivity.ComponentExecutionMicroActivity.runCil(ComponentExecutionMicroActivity.java:126)
         at fuego.server.execution.microactivity.ComponentExecutionMicroActivity.execute(ComponentExecutionMicroActivity.java:84)
         at fuego.server.execution.microactivity.MicroActivityEngineExecutionHandler.executeActivity(MicroActivityEngineExecutionHandler.java:57)
         at fuego.server.execution.ImmediateActivity.execute(ImmediateActivity.java:42)
         at fuego.server.execution.DefaultEngineExecution$AtomicExecutionTA.runTransaction(DefaultEngineExecution.java:304)
         at fuego.transaction.TransactionAction.startBaseTransaction(TransactionAction.java:470)
         at fuego.transaction.TransactionAction.startTransaction(TransactionAction.java:551)
         at fuego.transaction.TransactionAction.start(TransactionAction.java:212)
         at fuego.server.execution.DefaultEngineExecution.executeImmediate(DefaultEngineExecution.java:123)
         at fuego.server.execution.DefaultEngineExecution.executeAutomaticWork(DefaultEngineExecution.java:62)
         at fuego.server.execution.EngineExecution.executeAutomaticWork(EngineExecution.java:42)
         at fuego.server.execution.ToDoItem.executeAutomaticWork(ToDoItem.java:251)
         at fuego.server.execution.ToDoItem.run(ToDoItem.java:536)
         at fuego.component.ExecutionThread.processMessage(ExecutionThread.java:775)
         at fuego.component.ExecutionThread.processBatch(ExecutionThread.java:755)
         at fuego.component.ExecutionThread.doProcessBatch(ExecutionThread.java:142)
         at fuego.component.ExecutionThread.doProcessBatch(ExecutionThread.java:134)
         at fuego.fengine.ToDoQueueThread$PrincipalWrapper.processBatch(ToDoQueueThread.java:450)
         at fuego.component.ExecutionThread.work(ExecutionThread.java:839)
         at fuego.component.ExecutionThread.run(ExecutionThread.java:408)
    Caused by: fuego.components.SQLException: [BEA][Oracle JDBC Driver][Oracle]ORA-01461: can bind a LONG value only for insert into a LONG column
         at fuego.sql.TableSQLObject.implicitStore(TableSQLObject.java:409)
         at fuego.sql.TableSQLObject.store(TableSQLObject.java:340)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at fuego.lang.JavaClass.invokeMethod(JavaClass.java:1410)
         at fuego.sql.SQLObject.invoke(SQLObject.java:364)
         at fuego.lang.Invokeable.invokeImpl(Invokeable.java:234)
         at fuego.lang.Invokeable.invokeDynamic(Invokeable.java:188)
         at EstablishmentManagement.EMMaintainPeopleProcess.Default_1_0.Instance.CIL_sendToHQ(Instance.xcdl:100)
         at EstablishmentManagement.EMMaintainPeopleProcess.Default_1_0.Instance.CIL_sendToHQ(Instance.xcdl)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at fuego.component.ExecutionThreadContext.invokeMethod(ExecutionThreadContext.java:512)
         ... 23 more
    Caused by: java.sql.SQLException: [BEA][Oracle JDBC Driver][Oracle]ORA-01461: can bind a LONG value only for insert into a LONG column
         at albpm.jdbc.base.BaseExceptions.createException(Unknown Source)
         at albpm.jdbc.base.BaseExceptions.getException(Unknown Source)
         at albpm.jdbc.oracle.OracleImplStatement.execute(Unknown Source)
         at albpm.jdbc.base.BaseStatement.commonExecute(Unknown Source)
         at albpm.jdbc.base.BaseStatement.executeUpdateInternal(Unknown Source)
         at albpm.jdbc.base.BasePreparedStatement.executeUpdate(Unknown Source)
         at fuego.jdbc.FaultTolerantPreparedStatement.executeUpdate(FaultTolerantPreparedStatement.java:623)
         at fuego.sql.TableSQLObject.insert(TableSQLObject.java:626)
         at fuego.sql.TableSQLObject.implicitStore(TableSQLObject.java:391)
         ... 39 more
    Edited by: user10778731 on 21-Jan-2010 06:17

    Suspect you're not going to like this answer, but I never use the store() method for a database heir object anymore.
    The store() database method has been broken and then fixed and then broken again on too many release cycles to trust that it will work consistently as MPs/Hotfixes are applied. I'd suspect that your "String(4000)" problem might also be related to using the store() method.
    Others will probably disagree, but only use the OOTB PBL (JDBC) SQL or Dynamic SQL in the PBL logic. In your case, I think you might be best served by using Dynamic SQL. With Dynamic SQL you don't run into the shortcomings of JDBC SQL (String(4000) might be one of them) and you can then test / debug your SQL in your favorite DB tool of choice first (e.g. Toad, Squirrel, Sql Plus). Once successfully tested, you can then paste it back into your PBL.
    Dan

  • Mining Models used in SQL Developer 3.0 and models created PL/SQL scripts

    Hi,
    Pardon my ignorance if some of my questions are very basic. I am just gaining understanding about building/using mining models.
    I installed sql developer and went thru some OBE exercises to build models ( classification models)
    While building workflows the exercise required to supply data for the pre built models ( the four models pre-created). The question is - is this exercise is about building models or using models ?
    How those pre-built models were created? Are these models are restricted in their usage. or are they generic models that they can be applied for solving similar problems?
    What type of models can be used in workflows?
    I am also seeing some smaples of pl/sql scripts used in creating some models. Is it correect to assume they are created using PL/SQL APIs ( DBMS_DATA_MINING, DBMS_DATA_MINING_TRANSFORM etc).
    What is the differrence between these two model building process ?
    Thanks

    Hi,
    The OBE exercises show you both how to build models and then to apply (Score) new data using the built models.
    A model is always built using some form of input data, so it is built specifically with that form of data in mind.
    It is not a generic model at all.
    When you apply a model you provide data in the same format as the original data.
    In the case of a Classification or Regression model, you are applying the model to generate a prediction on new data that conforms with the build data provided to the model.
    The online help provides details on all the models that are available.
    Data Miner uses the data mining pl/sql packages (package name DBMS_DATA_MINING) to create and test models.
    There are also sql data mining prediction functions as well.
    Thanks, Mark

  • JMS/AQ: Setting properties for JMS message using PL/SQL

    I have created a procedure in PL/SQL that uses JMS messages, and now I need to include a property so that the subscriber can use a message selector to filter out unwanted messages. Is this possible using PL/SQL?
    A previous post said: "... But you can have properties in the message payload itself and also define selectors on the message content ...". But I looked at Sun's tutorial and there it said: "A message selector cannot select messages on the basis of the content of the message body."
    I have 300 different screens and messages apply only to one screen at a time. When the user is looking at screen 'A' I want him to only recieve messages that apply to screen 'A'. I thought I would do this with message selector, but is there any other way?
    Here is my code(borrowed from an earlier post)
    PROCEDURE ENQUEUE_JMS_MESSAGE AS
    BEGIN
    DECLARE
    Enqueue_options DBMS_AQ.enqueue_options_t;
    Message_properties DBMS_AQ.message_properties_t;
    Message_handle RAW(16);
    User_prop_array SYS.AQ$_JMS_USERPROPARRAY;
    Agent SYS.AQ$_AGENT;
    Header SYS.AQ$_JMS_HEADER;
    Message SYS.AQ$_JMS_TEXT_MESSAGE;
    Message_text VARCHAR2(100);
    BEGIN
    Agent := SYS.AQ$_AGENT('',NULL,0);
    User_prop_array := SYS.AQ$_JMS_USERPROPARRAY();
    Header := SYS.AQ$_JMS_HEADER( Agent, '', 'aq1', '', '', '', User_prop_array);
    Message_text := 'Message 1 from PL/SQL';
    Message := SYS.AQ$_JMS_TEXT_MESSAGE(Header, LENGTH(Message_text), Message_text, NULL);
    DBMS_AQ.ENQUEUE(queue_name => 'tstopic',
    Enqueue_options => enqueue_options,
    Message_properties => message_properties,
    Payload => message,
    Msgid => message_handle);
    END;
    END;
    -Christer

    Thanks for the answer. I managed to set the Correlation id and retrieve it using getJMSCorrelationID(). But I did not manage to use the MessageSelector on it. I have used the Topicbrowser which is not part of the JMS standard? I tried to enqueue the messages using Java too and tried to use the topicbrowser on both JMSCorrelationID and user defined properties withou success. Is there some special requirements of the TopicBrowser?
    Enumeration messages;
    oracle.jms.TopicBrowser browser =tsess.createBrowser(topic, "TS", "JMSCorrelationID = 'TST'");
    int count = 0;
    messages = browser.getEnumeration();
    if(messages.hasMoreElements())
    System.out.println("message"); //never executed
    dtxtmsg = (TextMessage)(tsub1.receiveNoWait()) ; //returns a message
    String corrID = dtxtmsg.getJMSCorrelationID(); //returns: TST
    Thanks for your help so far...it would really save my day if you have some ideas on this too!
    -Christer

  • Optimizing an SQL Query using Oracle SQL Developer

    Hi ,
    Currently i am using Oracle SQL Developer as my Database IDE .
    Is it possible to use Orqcles SQLDeveloper for the purpose of Optimizing an SQL Query ??
    For example assume i am having a query as :
    Select from Tranac_Master where CUST_STATAUS='Y' and JCC_REPORT='N'*
    Could anybody please tell me how can i use Oracle SQL Developer to optimize this query or any other SQL queries ??
    Please share your ideas , thanks in advance .

    1. Your query looks very simplistic as it is, so I fail to see how you can better optimise it (unless 'Tranac_Master' is a view, in which case I'd need to see the view details).
    2. No tool can automagically optimise your SQL to any degree of practical use. Very minor adjustments may be possible automatically, but really it is a question of you knowing your data & database design accurately, and then you applying your expert knowledge to tune it.

  • Read, Modify and Apply Report XML using Java Script

    Hi Guys,
    Is there any way that we can Pragmatically Read, Modify and Apply Report XML using Java Script or some other way.
    Thanks
    Kaushik
    Edited by: Kaushik K on Jun 20, 2012 8:36 PM

    Requirement ::
    Users should be able to add Column to the Report Dynamically at Runtime.
    (There are around 1000+ Users, Answers Approach is not acceptable)
    So we are planning to provide a Multi Select / Shuttle Box Option for Users to add Columns dynamically. (Only for Table View)
    What we planned to DO ::
    Create a Presentation Variable Prompt, Which reads the Metadata Table (Presentation Table.Column Name, populated using the Metadata Dictionary)
    And Create a report with One Column and the Column Fx like @{var_dynamic_columns}{'"Time"."Year","Time"."Month"'}
    With this, OBIEE is rewriting the Logical SQL Currently as "Select "Time"."Year","Time"."Month" from "A - Sample Sales" "
    But getting an error
    The number of columns returned in retrieving column metadata was invalid (expected: 1; received: 2)
    So we want to see, if we can rewrite the Advanced XML of the Report to have dynamic columns based on the Values from the Presentation Variable.
    Please help me if this is a viable solution or any other better solution.

  • Web service invocation using pl/sql

    Hi
    Am trying to invoke a webservice using PL/SQL.
    Any ideas?
    I will be recieving the response as XML and then present the information using XSL which I have ready.
    Or any other ideas to invoke Siebel Analytics report from portal (no BPEL). I have WSDL.

    1006367 wrote:
    I am calling a Web Service(RoadNet Application) from Oracle PL/SQL(11g Database). I would not use UTL_DBWS. I had to do another web service interface recently, had a look at UTL_DBWS, and again decided not to use it. Simply put. It lacks.
    I use SOAPUI (OpenSource/free version) to interrogate the web service (read wsdl) and format a sample SOAP envelope to use.
    I then use UTL_HTTP and code a HTML POST for that web service, using the SOAPUI generated envelope as template. Supporting WSSE is also not a problem (easily done using PL/SQL).
    I posted an example of my approach in {message:id=10448611} almost a year ago - and recent experience having looked at both UTL_DBWS and the plan vanilla PL/SQL HTTP approach, I still recommend the latter.

  • Error using Extended SQL Function substr

    I want to be able to look for the first three letters of a month in the XML and if found replace the 3 letter month (for example SEP-05 to September 05). I have tried the following which throw a namespace exception. Please let me know what I may be doing wrong?
    1. <?if:(xdofx:substr(../fsg:ColContext[2]/fsg:ColHeadLine2,1,3)='SEP'?>September<?end if?> should give me September.
    The above fails with: Font Dir: E:\Program Files\Oracle\XML Publisher Desktop\Template Builder for Word\fonts
    Run XDO Start
    RTFProcessor setLocale: en-us
    FOProcessor setData: E:\Work\Bacardi\Reports\XML\US GAAP BALSHEET\XML BL Dir Rpt BS YTD_0126.xml
    FOProcessor setLocale: en-us
    java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeNewXSLStylesheet(XSLT10gR1.java:514)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:192)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:156)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:916)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:869)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:204)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1535)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:925)
         at RTF2PDF.runRTFto(RTF2PDF.java:590)
         at RTF2PDF.runXDO(RTF2PDF.java:443)
         at RTF2PDF.main(RTF2PDF.java:237)
    Caused by: oracle.xdo.parser.v2.XPathException: Namespace prefix 'xdofx' used but not declared.
         at oracle.xdo.parser.v2.XSLProcessor.reportException(XSLProcessor.java:782)
         at oracle.xdo.parser.v2.XSLProcessor.newXSLStylesheet(XSLProcessor.java:564)
         ... 15 more
    2. For the year, I would use another form field and do something like this next to the month above: <?xdofx:substr(../fsg:ColContext[2]/fsg:ColHeadLine2,5,2)?> for a result of '05'

    Hasan
    XSL has many native string manipulation functions so you do not need to use our SQL functions when a native XSL one will do:
    <?if:substring(normalize-space(../fsg:ColContext[2]/fsg:ColHeadLine2),1,3)='SEP'?>September<?end if?>
    See that dang normalize space function again ... had to use it on my FSG sample.
    Would it not be easier to either:
    1. Have the FSG generate the September YYYY format or
    2. Have FSG generate XSD date formats, 'YYYY-MM-DD', then you can just specify the date format in the form fields
    Regards, Tim

  • Using a SQL data source and XML data source in the same template

    I am trying to develop a template for the Request for Quote report generated in Apps 11.5.10. I have loaded the data from the XML output into the template, but I am missing one field - I need the org_id from the po_headers table. Is it possible to use a sql data source (i.e., "select org_id from po_headers_all where po_header_id = [insert header_id from xml data]...") in addition to the xml data source to populate the template at runtime? When you use the Insert > SQL functionality is it static at the time the template is created, or does it call to the database at runtime? I've looked through all the docs I could find, but this isn't clear.
    Thanks for any help or suggestions you may have.
    Rhonda

    Hi Pablo
    Thats a tough one ... if you go custom with a data template you will at least get support on the data template functionality ie you have a problem when you try and build one. You will not get support on the query inside the data template as you might have gotten with the Oracle Report, well you could at least log a bug against development for a bad query.
    Eventually that Oracle Report will be converted by development anyway, theres an R12 project going on right now to switch the shipped OReports to data templates. AT this point you'll be fully supported again but:
    1. You have to have R12 and
    2. You'll need to wait for the patch
    On reflection, if you are confident enough in the query then Oracle will support you on its implementation within a data template. Going forward you may be able to swap out your DT and out in the Oracle one without too much effort.
    Regards, Tim

  • How can i use one SQL statement to solve problem?

    How can i use one SQL statement to solve the question below?
    For a Table named A, there is a column named F(char type).
    Now select all the records where F like '%00' and update their F value to '%01'
    Just one SQL statement.Do not use PL/SQL block.
    How to do that?
    Thanks.

    What is the data volume for this table?
    Do you expect lots of rows to have '%00' as their value?
    Following two statements come to mind. Other experts would be able to provide better alternatives:
    If you have index on SUBSTR(f, 2):
    UPDATE A
    SET    f = SUBSTR(f,
                      1,
                      length(f) - 2) || '01'
    WHERE  substr(f,
                  -2) = '00';If most of the rows have pattern '%00':
    UPDATE A
    SET    f = SUBSTR(f,
                      1,
                      length(f) - 2) ||
               DECODE(SUBSTR(f,
                             -2),
                      '00',
                      '01',
                      SUBSTR(f,
                             -2));

  • Using a SQL Query in an Alert and Matching a String

    I've created an alert in 12.0.4 using a SQL Query and the field that I'm trying to match is a string.  Originally the query returned multiple rows but when the alert still didn't fire, I modified the query WHERE clause to return only one row:
    NAME                                RESPONSE
    Are area lights working?            No
    My expression in the metric is RESPONSE.  In the Monitor I'm matching a string equal to No.  (Do I need double quotes around the matchvalue?  Single quotes?  No quotes?)  The metric is in the 15min scan group, the role is xMII Developers and I'm in that role. The monitor alert string is ' =  '.  Both metric and monitor are active and I've subscribed to the monitor.  Other alerts in the 15min scan group (all based on tag queries) are firing off properly.
    Why is nothing showing up in the Alert Log?
    David Macindoe

    David,
    Did you figure out the answer?  If not, I will try to find someone to address your question.
    Mike

  • How can we update data in LDAP server using PL/SQL.

    Hi,
    How can we update data in LDAP server using PL/SQL program.
    Is there any sample code for refrence.
    Thanks,
    Tarun

    Hi Justin,
    Thanks for your help. You got my correct requirements.
    Tim's example returning all the attributes of current user which is admin user. Please correct me if I am wrong.
    I have the following information:
    the admin user and password,server info , port and ldap_base for admin.
    I have uid and password for regular user, I am trying find the ldap_base for regular user, which may be different from adminuser.
    Please help me.
    Thanks,
    Edited by: james. on Jan 12, 2009 5:39 PM

Maybe you are looking for