How to create a Service based on complex query

Hi,
I'm using JDev 11.1.2.2.0 for developing fusion based application based on EJB3.0 and JPA. I search on net and got a link for sample application as shown below:
http://www.oracle.com/webfolder/technetwork/tutorials/obe/jdev/obe11jdev/ps1/ejb/ejb.html#t2s1
But above application is based on "Entities based on Tables" but my requirement to build a service based on query which contains multiple tables which means I want to create a generic one...
please let me know what I need to change or please provide any link for docs.

Hi Desmukh,
I want to create a wsdl for complex queries based on ADF fusion applicaiton using EJB3.0 and JPA...!
the link which you provided 'entity with tables' which is restricting for my requirement but I want similar implementation for complex queries :(

Similar Messages

  • How to create Web Service based on PI WSDL message

    Hi all,
    we have following scenario:
    Within PI (version 7.1) we set up a message type and inbound service interface. This service interface should send the PI message to a web service running on a SAP J2EE (version 7.01). As the PI message is sent as WSDL I thought it should be easy to build a web service on the SAP J2EE based on this WSDL from PI.
    Unfortunately, I have problems creating the Web Service.
    For my current project we integrated the NWDI to the SAP NetWeaver Developer Studio and I'm required to add the Web Service to an existing DC (Development Component) within the NWDI.
    What I tried so far is:
    - I created a Deployable Proxy Project and within this I created a Client Proxy Definition based on the WSDL from the PI. But I can't add this Proxy to the DCs of the NWDI and I don't know how to implement my own coding here in order execute specific functions.
    - I created a new class within the NWDI DC and a public method. Based on this I created a Virtual Interface and a Web Service Definition (WSD). Then I added this to a Web Service Deployment Descriptor. I uploaded this to the SAP J2EE. But I'm not able to access this and I don't know hoe to assign the WSDL here.
    I also tried here to create a client proxy based on this WSD as I thought I might assign the WSDL here. But I don't see the WSD in the list of Web Services uploaded to the SAP J2EE...
    Can you please advice me how to create a Web Service in such an environment?
    regards
    René Jurmann

    Hi Tahir,
    sorry that you needed to wait this long - but this is how I created the web service:
    The steps on how to create the web service in NetWeaver Developer studio are nearly the same as described in the blog http://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/5838. [original link is broken] [original link is broken] [original link is broken]
    Some steps I just skipped and some others I added. Some of the steps I did the way I described it as I needed to connect the web service with the SAP PI.
    Prerequisites:
    Add Java Perspective and J2EE Development Perspective to the open perspectives.
    Within "Window - Preferences - Web Services" check "Soap extensions visible in the virtual interface editor"
    The SDM of the corresponding SAP J2EE is configured within "Window - Preferences"
    Create a Development Component (DC) with type "J2EE -> EJB Module"
    The business logic of the web service will be implemented in an Enterprise Java Bean (EJB). So first the EJB component must be created:
         Choose "File -> New -> Other"
         In opening PopUp choose "Development Component -> Development Component Project"
         Select the Software Component for which you want to add the DC (e.g. "Local Development -> MyComponents")
         Choose now vendor, name and type:
              vendor is an alpha-numeric string of 20 characters starting with a letter - all in lower case
              name is an alpha-numeric string starting with a letter - all in lower case
              vendor and name concatenated must not be longer then 40 characters
              the name can be separated into different part using "/" as separator
              each part of the name must not be longer than 8 characters
              the type is "J2EE - EJB Module"
              you can specify a Caption as general description for the web service
    Create new EJB
    To create the EJB itself:
         In J2EE DC Explorer of J2EE Development Perspective expand new DC and right-click on folder "ejbModule"
         Choose "New - EJB" with following details:
              EJB Name: <name as for PI service Interface to be created - starting in upper case>
              EJB Project: <pre selected>
              Bean Type: Stateless Session Bean
              Default EJB Package: <corresponds to namespace in PI>
              generate default interfaces: Checked
    Regarding the "Default EJB Package" this should be created according the namespace in PI for which all PI objects will be created. This only applies if you have some naming conventions here.
    Example:
    Namespace in PI is:  http://company.net/pi/SOFTWARE_COMP/Application
    The corresponding package then is: net.company.pi.software_comp.application
    Implement coding for web service
    As the web service will be called via PI some transfer variables will be submitted. Most likely, those variables will not be standard type (e.g. String) but a complex type. Those types must be generated as Java classes. Below an example of a complex type I needed:
    Data Type
    net.company.pi.software_comp.application.types.MessageProcessingInformation
    Structure:
         Element name          Element type
         sendingSystemID          String
         interfaceID               String
         businessProcessVariantCode     String
         testIndicator               Boolean
    For every element described a public "get", "set" and "has" method must be created in the corresponding Java class:
    package net.company.pi.software_comp.application.types;
    import java.io.Serializable;
    public class MessageProcessingInformation implements Serializable {
         protected String sendingSystemID;
         protected String interfaceID;
         protected String businessProcessVariantCode;
         protected Boolean testIndicator;
         public String getSendingSystemID() {
              return sendingSystemID;
         public void setSendingSystemID(String value) {
              this.sendingSystemID = value;
         public boolean hasSendingSystemID() {
              if(sendingSystemID != null && !sendingSystemID.equals("")){
                   return true;
              return false;
    All Java classes representing complex types and all classes referenced here (used for sub-types) must implement java.io.Serializable. Java standard types which do not implement this class must not be used as sub-types.
    As soon as all data types are declared the real business logic can be implemented:
         In J2EE DC Explorer of J2EE Development Perspective expand DC - "ejb-jar.xml" - <Name> and double click on "ejbCreate"
         In detail view select folder "Business Methods" and click "Add"
         choose name of business method - this should be the same as the PI message type used for the service interface - starting lower case
         return type should be "void"
         add needed parameters fully qualified - including package (as specified in PI and created previously in DC)
         you can mark certain parameters as array if necessary
    Remark:
    It might be that after saving you get an error. This might be as the package name of one component is copied to the corresponding Java class at the very beginning (before the package declaration within the Java class). Simply delete the string here.
    It also might be, that the new business method is only defined in the remote interface class but not in the bean class. Just create an according method in the bean class.
    Within the newly created business method within the bean class you can now implement the business logic.
    Create a DC with type "J2EE -> Enterprise Application"
    In order to create the "real" web service and deploy it to the J2EE an Enterprise Application project has to be created. So create a new DC as for the EJB Module but choose as type "J2EE -> Enterprise Application".
    After the DC is created right click on the EJB DC and choose "Add to EAR Project". Choose the new DC.
    Create web service for EJB
    As soon as you implemented the business logic you can create the "real" web service. Therefore:
         Right click on the EJB name below "ejb-jar.xml"
         Choose "New - Web Service"
         Choose proper "Web Service Name" and "Configuration Name" (probably oriented at the EJB name)
         Copy the URL of the web service - you'll need it later for PI configuration
         on the second next screen use the same name for "Virtual Interface" and "Web Service Definition" (the name should be the name of the "Endpoint")
         the "EAR Project" should be preselected
    Unfortunately, the web service can't be used in its current configuration to be accessed by PI. Therefore the Virtual Interface must be changed. To do so, expand folder "Virtual Interfaces" and double click the virtual interface created.
    Within the detail view expand in tabs "Mapping" and "Types" the complete folder structure. For any "SOAP Extension" where a namespace can be defined use as namespace the corresponding namespace in PI (e.g. http://corpintra.net/pi/CBFC_GLOBAL_SAP_APPL/BillerDirect) but do not change any "Soap Extension" of a standard Java type. (if you don't have any naming convetions for namespaces in PI you can leave the SOAP Extension here. But then the namespace in PI should be set accordingly.)
    Probably it can be necessary on top level "Soap Extensions" in tab "Mapping" to leave "Use Namespaces for Parameters" unchecked. For some of my web services this parameter must be checked for others not - just try.
    If you can define a "New Name", "Local Name" or "Item Label" for a Soap Extension then use a name with starting upper case letter. (For Java Naming conventions most of the data type names will start with lower case letters.) Especially the method name must be renamed this way in order to stick to the PI namings.
    As a last point to change here check in tab "Mapping" all "Incoming Parameters" which you specified as array. Use for those as "New Name" a different name - do not just simply change from lower case to upper case. This is necessary as on PI we need to create two levels although here only one is specified.
    For any own sub-type declared as array the name within the coding should also differ from the corresponding Java Class name the type refers to.
    If all this is done you can deploy the web service to the J2EE:
         right click on "Enterprise Application" DC and choose "Development Component - Build..." and build all corresponding components
         right click on "Enterprise Application" DC and choose "Development Component - Deploy"
    Test the new web service via <J2EE URL>/wsnavigator/enterwsdl.html
    Create PI interface
    After the web service is created successfully the PI integration can be started.
    Therefore, within the Enterprise Services Builder create a data type according to the web service definition. All components defined on top-level for this data type should be declared as incoming parameter for the web service business method. Therefore it could be necessary to create some sub data types on PI first and add those to the "master" data type.
    Ensure that the names of the components correspond to the names defined in the web service (see virtual interface here). Those names must exactly be the same - including lower/upper case. Also take care for the ordering of the components.
    In case you need to include arrays following applies:
    The upper level is of occurrence "1:1". This has only one sub-entry with occurrence "1:n". The names for upper and sub-level must not equal.
    Based on the data type a message type is created. The name of the message type must be exactly the same as the name of the web service business method. (Hint: the name of the web service business method was most likely changed in the virtual interface. Then this name must correspond to the message type name.) Based on the message type an asynchronous inbound interface is to be created (which will be referred in the Integration Directory). The operation name for this interface (left panel) should be the same as the name for the web service business method.
    Create PI mappings and routings
    How to map (message mapping and operation mapping) from source to the web service message I wont explain here as this depends on the source message. The only important things here are:
         When creating the SOAP communication channel within the Integration Builder the "Target URL" is:
              <J2EE URL>/<Access URL as specified in web service creation>?wsdl&style=document
         The soap action is the name of the web service business method.
         Most likely the web service needs authentication to be executed.

  • How to create multiple idocs based on complex condition

    HI Users,
    my scenario is jms(xml file) to idoc. for each file have multiple records for each record i need to create multiple idocs.
    source structure:
    <lineitem>
    <student sid="cid">456</student>
    <hreference>
    <reference rtype="number">123</reference>
    </hreference>
    <hreference>
    <reference rtype="number">789</reference>
    </hreference>
    <hreference>
    <reference rtype="char">147</reference>
    </hreference>
    now condition is One input message must create only one output message for each unique  rtype="number" and sid="cid" combination.
    for example
    1. rtype="number" and sid="cid" the value combination means 123456 for this one idoc
    2.  rtype="number" and sid="cid" the value combination means 789456 for this one idoc
    --> the below file shows with out sid="cid"
    <lineitem>
    <student sid="abc">456</student>
    <hreference>
    <reference rtype="number">123</reference>
    </hreference>
    <hreference>
    <reference rtype="number">789</reference>
    </hreference>
    <hreference>
    <reference rtype="number">147</reference>
    </hreference>
    in this case we have to consider only rtype="number" so here we need to create  3 idocs.
    Could anyone help me in this regard.
    Thanks in advance

    Hi Swathip,
    Change the occurence of the IDoc to "unbounded", so that multiple IDocs can get create
    Try with below logic
    If (SID = "CID")
    Then
         If(rtype = "number")
              concat(student,reference ) ---> removeContext ---> Idoc          
    Else
         rtype ---> removeContext ---> Idoc
    If combination of unique  student and reference can occur more than once in the XML, use sort command and splitByValue (Value Change)
    Edited by: chandra shekhar on Jul 3, 2011 12:53 PM

  • How to create a diagram based on the query?

    Hi All,
    I want to create a diagram which will show a structure based on the data in the tables.
    For example:-
    if in a table, we have on two columns,
    one have unique breed of animal and other columns have sub-breeds under that breed. it is one to many mapping.
    in some other table,we have on two columns,
    one have unique sub-breed of animal and other columns have again sub-breeds under that breed. it is one to many mapping.
    i want to display the diagram as shown at the following url:- http://www.signosemio.com/a_analyse-par-classement.asp (diagram:- The naïve ontological classes)
    At the place of Boxes, i will show images.
    but i am not able to generate this diagram.
    please help.

    I am afraid, the Google Visualization plugin (which is used internally by that apex plugin) does not support multiple parents.
    The documentation page says the following
    Each node can have zero or one parent node, and zero or more child nodes.I tried adding an extra row for a child with an additional parent, but it removed the old parent association for that record in the chart
    You might have to some other plugin which supports that or find an JS/jQuery plugin that renders as per your requirement and then write the code yourself to pass the data to JS function from the page.

  • How to create a crosstab based on BW Query which has key figure structure

    Hi,
    We are on CR 2008 SP1.
    We have an existing BW query with custom Characteristics structure in the "Columns" section and a custom Key Fugure structure in the "Rows" section in the BW query designer.
    Cell editor has been used to define formulas of the cells.
    We wish to build a crystal report on top of the query.
    On the crystal report on top of the query we get the characteristics structure and individual key figure elements. As already discussed in multiple fourm posts, this is the expected behaviour.
    We are using a cross tab and in the column section, I have put the "Characteristic" structure  in the  "columns" section in the crosstab using the crosstab expert. This leads to horizonatal column headings as per expectation.
    Within the characteristics structure we have multiple fields which description "%" with diffeent formula's defined on the BW query designer. On the Cyrtsl Report, when we get the columns in the crosstab, we get only a single "%" field. All other "%" fields are not visible.
    A. Is there a way to get all fields in in case of same description?
    I tried putting in the Key Figure elements in the "Rows" section, but was not able to get desired output.
    Experts: Can you advice how this report can be built?
    Any help will be appretiated.
    Rgds

    I am interested... How did you solve it?

  • How to create a service entry sheet based from the PO

    how to create a service entry sheet based from the PO
    Gurus,
    I am creating a service entry sheet from the PO but I am getting an error of u201CPlease maintain services or limits Message no. SE029- Diagnosis(You cannot enter data until the PO item has been maintained correctly) u201C
    The document type of the PO is standard NB, account assignment category is Q- (Proj make to order) and the item category is D(service). Then I am trying also create a PR using account assignment category is Q- (Proj make to order) and the item category is D(service) but still cannot proceed, a message asking me to enter a service entry number. What I know the process is create a PO(maybe based from PR) then post the GR then create a service entry sheet in ML81N but I cannot proceed. Just creating a PR or PO using those mentioned account assignment and item category and getting an error of need to enter a service entry sheet number.
    Please help.thanks!

    HI,
    Process for Creating Service Entry Sheet
    Transaction Code :    ML81N
    1)To open the respective Purchase Order, Click on the u2018Other Purchase Orderu2019, then enter the Purchase Order No.
    2)Click on the u2018Create Entry Sheetu2019 icon(3rd Icon on Top-Left)
    3)Give Short Text (e.g. R/A Bill No. 1) and top service entry sheet number also generated.
    4)Click u2018Service Selectionu2019 Icon on the Bottom of the Screen.
    5)For the 1st Time, when we are making Service Entry Sheet for a respective Purchase Order, we need to u201CAdopt Full Quantityu201D by clicking the Check box next to it, then Enter.  (*For the next time, no adoption is required, just continue)
    6)Select the respective Services by clicking on the Left Hand Side, then Click u2018Servicesu2019 (Adopt services) icon on the Top.
    7)Give the completed Quantity, then Click u2018Acceptu2019 icon(a green flag on the top)
    8)Save .
    9)Service Entry Sheet is SAVED and account posting made.
    Hope, it is useful for you,
    Regards,
    K.Rajendran

  • How to create Web services to communicate InfoPath forms to Share Point lists ?

    How to create Web services to communicate InfoPath forms to Share Point lists ?

    Hi,  
     As per your posting and my understanding, you wanted to communicate your infopath with SharePoint list/library. Please refer the below link(s) which may help you to solve your issue.
    http://blogs.msdn.com/b/russmax/archive/2012/08/17/want-to-call-sharepoint-2010-web-services-within-browser-based-infopath-2010-forms.aspx
    http://jaliyaudagedara.blogspot.in/2011/03/submitting-data-to-sharepoint-2010-list.html
    or 
    http://blogs.msdn.com/b/infopath/archive/2007/03/26/submitting-to-a-sharepoint-list.aspx
    If you need more help please let usknow
    Sekar - Our life is short, so help others to grow
    Whenever you see a reply and if you think is helpful, click "Vote As Helpful"! And whenever you
    see a reply being an answer to the question of the thread, click "Mark As Answer

  • How to create web service client

    Hi All,
    I am new to web services .Can any body explain how to create web service client ....
    Please give the give the discription step wise.
    Thanx
    Arun

    Hi Krishna,
    Yes it is possible.
    Check this Link
    [JDeveloper Web Service|http://www.oracle.com/technology/obe/obe1013jdev/10131/10131_wstopdown/wstopdown.htm#t2]
    http://www.oracle.com/technology/obe/obe1013jdev/10131/10131_wstopdown/wstopdown.htm#t2
    I strongly suggest you to go for Eclipse, instead of Netbeans or Jdeveloper incase of WebService. If you want to run your code in all the Server without making any changes go for Eclipse based development for Web Service.
    Kindly let me know if you need some more inputs.
    Regards,
    Zack

  • How to create a report based on a DataSet programatically

    I'm working on a CR 2008 Add-in.
    Usage of this add-in is: Let the user choose from a list of predefined datasets, and create a totally empty report with this dataset attached to is. So the user can create a report based on this dataset.
    I have a dataset in memory, and want to create a new report in cr2008.
    The new report is a blank report (with no connection information).
    If I set the ReportDocument.SetDataSource(Dataset dataSet) property, I get the error:
    The report has no tables.
    So I must programmatically define the table definition in my blank report.
    I found the following article: https://boc.sdn.sap.com/node/869, and came up with something like this:
    internal class NewReportWorker : Worker
          public NewReportWorker(string reportFileName)
             : base(reportFileName)
    public override void Process()
             DatabaseController databaseController = ClientDoc.DatabaseController;
             Table table = new Table();
             string tabelName = "Table140";
             table.Name = tabelName;
             table.Alias = tabelName;
             table.QualifiedName = tabelName;
             table.Description = tabelName;
             var fields = new Fields();
             var dbField = new DBField();
             var fieldName = "ID";
             dbField.Description = fieldName;
             dbField.HeadingText = fieldName;
             dbField.Name = fieldName;
             dbField.Type = CrFieldValueTypeEnum.crFieldValueTypeInt64sField;
             fields.Add(dbField);
             dbField = new DBField();
             fieldName = "IDLEGITIMATIEBEWIJS";
             dbField.Description = fieldName;
             dbField.HeadingText = fieldName;
             dbField.Name = fieldName;
             dbField.Type = CrFieldValueTypeEnum.crFieldValueTypeInt64sField;
             fields.Add(dbField);
             // More code for more tables to add.
             table.DataFields = fields;
             //CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo info =
             //   new CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo();
             //info.Attributes.Add("Databse DLL", "xxx.dll");
             //table.ConnectionInfo = info;
             // Here an error occurs.
             databaseController.AddTable(table, null);
             ReportDoc.SetDataSource( [MyFilledDataSet] );
             //object path = @"d:\logfiles\";
             //ClientDoc.SaveAs("test.rpt", ref path, 0);
    The object ClientDoc referes to a ISCDReportClientDocument in a base class:
       internal abstract class Worker
          private ReportDocument _ReportDoc;
          private ISCDReportClientDocument _ClientDoc;
          private string _ReportFileName;
          public Worker(string reportFileName)
             _ReportFileName = reportFileName;
             _ReportDoc = new ReportDocument();
             // Load the report from file path passed by the designer.
             _ReportDoc.Load(reportFileName);
             // Create a RAS Document through In-Proc RAS through the RPTDoc.
             _ClientDoc = _ReportDoc.ReportClientDocument;
          public string ReportFileName
             get
                return _ReportFileName;
          public ReportDocument ReportDoc
             get
                return _ReportDoc;
          public ISCDReportClientDocument ClientDoc
             get
                return _ClientDoc;
    But I get an "Unspecified error" on the line databaseController.AddTable(table, null);
    What am i doing wrong? Or is there another way to create a new report based on a DataSet in C# code?

    Hi,
    Have a look at the snippet code below written for version 9 that you might accommodate to CR 2008, it demonstrates how to create a report based on a DataSet programmatically.
    //=========================================================================
    +           * the following two string values can be modified to reflect your system+
    +          ************************************************************************************************/+
    +          string mdb_path = "C:
    program files
    crystal decisions
    crystal reports 9
    samples
    en
    databases
    xtreme.mdb";    // path to xtreme.mdb file+
    +          string xsd_path = "C:
    Crystal
    rasnet
    ras9_csharp_win_datasetreport
    customer.xsd";  // path to customer schema file+
    +          // Dataset+
    +          OleDbConnection m_connection;                         // ado.net connection+
    +          OleDbDataAdapter m_adapter;                              // ado.net adapter+
    +          System.Data.DataSet m_dataset;                         // ado.net dataset+
    +          // CR variables+
    +          ReportClientDocument m_crReportDocument;          // report client document+
    +          Field m_crFieldCustomer;+
    +          Field m_crFieldCountry;+
    +          void CreateData()+
    +          {+
    +               // Create OLEDB connection+
    +               m_connection = new OleDbConnection();+
    +               m_connection.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + mdb_path;+
    +               // Create Data Adapter+
    +               m_adapter = new OleDbDataAdapter("select * from Customer where Country='Canada'", m_connection);+
    +               // create dataset and fill+
    +               m_dataset = new System.Data.DataSet();+
    +               m_adapter.Fill(m_dataset, "Customer");+
    +               // create a schema file+
    +               m_dataset.WriteXmlSchema(xsd_path);+
    +          }+
    +          // Adds a DataSource using dataset. Since this does not require intermediate schema file, this method+
    +          // will work in a distributed environment where you have IIS box on server A and RAS Server on server B.+
    +          void AddDataSourceUsingDataSet(+
    +               ReportClientDocument rcDoc,          // report client document+
    +               System.Data.DataSet data)          // dataset+
    +          {+
    +               // add a datasource+
    +               DataSetConverter.AddDataSource(rcDoc, data);+
    +          }+
    +          // Adds a DataSource using a physical schema file. This method require you to have schema file in RAS Server+
    +          // box (NOT ON SDK BOX). In distributed environment where you have IIS on server A and RAS on server B,+
    +          // and you execute CreateData above, schema file is created in IIS box, and this method will fail, because+
    +          // RAS server cannot see that schema file on its local machine. In such environment, you must use method+
    +          // above.+
    +          void AddDataSourceUsingSchemaFile(+
    +               ReportClientDocument rcDoc,          // report client document+
    +               string schema_file_name,          // xml schema file location+
    +               string table_name,                    // table to be added+
    +               System.Data.DataSet data)          // dataset+
    +          {+
    +               PropertyBag crLogonInfo;               // logon info+
    +               PropertyBag crAttributes;               // logon attributes+
    +               ConnectionInfo crConnectionInfo;     // connection info+
    +               CrystalDecisions.ReportAppServer.DataDefModel.Table crTable;+
    +               // database table+
    +               // create logon property+
    +               crLogonInfo = new PropertyBag();+
    +               crLogonInfo["XML File Path"] = schema_file_name;+
    +               // create logon attributes+
    +               crAttributes = new PropertyBag();+
    +               crAttributes["Database DLL"] = "crdb_adoplus.dll";+
    +               crAttributes["QE_DatabaseType"] = "ADO.NET (XML)";+
    +               crAttributes["QE_ServerDescription"] = "NewDataSet";+
    +               crAttributes["QE_SQLDB"] = true;+
    +               crAttributes["QE_LogonProperties"] = crLogonInfo;+
    +               // create connection info+
    +               crConnectionInfo = new ConnectionInfo();+
    +               crConnectionInfo.Kind = CrConnectionInfoKindEnum.crConnectionInfoKindCRQE;+
    +               crConnectionInfo.Attributes = crAttributes;+
    +               // create a table+
    +               crTable = new CrystalDecisions.ReportAppServer.DataDefModel.Table();+
    +               crTable.ConnectionInfo = crConnectionInfo;+
    +               crTable.Name = table_name;+
    +               crTable.Alias = table_name;+
    +               // add a table+
    +               rcDoc.DatabaseController.AddTable(crTable, null);+
    +               // pass dataset+
    +               rcDoc.DatabaseController.SetDataSource(DataSetConverter.Convert(data), table_name, table_name);+
    +          }+
    +          void CreateReport()+
    +          {+
    +               int iField;+
    +               // create ado.net dataset+
    +               CreateData();+
    +               // create report client document+
    +               m_crReportDocument = new ReportClientDocument();+
    +               m_crReportDocument.ReportAppServer = "127.0.0.1";+
    +               // new report document+
    +               m_crReportDocument.New();+
    +               // add a datasource using a schema file+
    +               // note that if you have distributed environment, you should use AddDataSourceUsingDataSet method instead.+
    +               // for more information, refer to comments on these methods.+
    +               AddDataSourceUsingSchemaFile(m_crReportDocument, xsd_path, "Customer", m_dataset);+
    +                              +
    +               // get Customer Name and Country fields+
    +               iField = m_crReportDocument.Database.Tables[0].DataFields.Find("Customer Name", CrFieldDisplayNameTypeEnum.crFieldDisplayNameName, CeLocale.ceLocaleUserDefault);+
    +               m_crFieldCustomer = (Field)m_crReportDocument.Database.Tables[0].DataFields[iField];+
    +               iField = m_crReportDocument.Database.Tables[0].DataFields.Find("Country", CrFieldDisplayNameTypeEnum.crFieldDisplayNameName, CeLocale.ceLocaleUserDefault);+
    +               m_crFieldCountry = (Field)m_crReportDocument.Database.Tables[0].DataFields[iField];+
    +               // add Customer Name and Country fields+
    +               m_crReportDocument.DataDefController.ResultFieldController.Add(-1, m_crFieldCustomer);+
    +               m_crReportDocument.DataDefController.ResultFieldController.Add(-1, m_crFieldCountry);+
    +               // view report+
    +               crystalReportViewer1.ReportSource = m_crReportDocument;+
    +          }+
    +          public Form1()+
    +          {+
    +               //+
    +               // Required for Windows Form Designer support+
    +               //+
    +               InitializeComponent();+
    +               // Create Report+
    +               CreateReport();+
    +               //+
    +               // TODO: Add any constructor code after InitializeComponent call+
    +               //+
    +          }+//=========================================================================

  • HOW TO CREATE A DFF BASED ON ORGANIZATION

    Hi,
    I want to create a DFF which would have 5 different context values, i want 2 of them to be available in one organization and other 3 in other organization, how i can achieve this.
    Regards,
    Usman.

    Hello,
    "HOW TO CREATE A DFF BASED ON ORGANIZATION"
    1- I will create a customized table having two columns one is for context name and other is for org_id,
    2- then i will create a value set on this table and will use this on 'Value Set' field on 'Descriptive Flexfield Segments' window.
    3- In the where clause of this value set i will pass org_id from profile $PROFILES$.ORG_ID,
    4- this will restrict the context based on org_id And user will only have context related to there org
    I have successfully achieved the above requirment.
    Find below the restriction you should follow so that Value set is available in LOVs on "Descriptive Flexfield Segments" window:
    Value sets used for context fields must obey certain restrictions or they will not be available to use in the Value Set field in the Context Field region of the Descriptive
    Flexfield Segments window:
    • Format Type must be Character (Char)
    • Numbers Only must not be checked (alphabetic characters are allowed)
    • Uppercase Only must not be checked (mixed case is allowed)
    • Right-justify and Zero-fill Numbers must not be checked
    • Validation Type must be Independent or Table
    If the validation type is Independent:
    • the value set maximum size must be less than or equal to 30
    If the validation type is Table:
    • the ID Column must be defined, it must be Char or Varchar2 type, and its size must
    be less than or equal to 30. The ID column corresponds to the context field value
    code (the internal, non-translated context field value).
    • the Value Column must be defined, it must be Char or Varchar2 type, and its size
    must be less than or equal to 80. The Value column corresponds to the context field
    value name (the displayed context field value).
    • the value set maximum size must be less than or equal to 80
    All context field values (the code values) you intend to use must exist in the value set. If
    you define context field values in the Context Field Values block of the Descriptive
    Flexfield Segments window that do not exist in the context field value set, they will be
    ignored, even if you have defined context-sensitive segments for them.
    Best Regards,
    Usman.

  • How to create a record based on the name of a file in the file-system?

    Hi,
    With a lot of pictures I want to have a database to gather some information about these pictures.
    First question is how to generate a record based on a file in the file system?
    e.g. the pictures are "c:\fotos\2009\01\disc_001.jpg" to "c:\foto\2009\01\dis_98.jpg" .
    now i want to create records with as one of the attributes the name of the picture (not the picture itself). how to create these records (based on the information of the file-ssytem). i.e. the number of records should be the same as the number of pictures.
    any suggestions?
    any reaction will be appreciated.
    Leo

    Link to Create directory
    http://www.adp-gmbh.ch/ora/sql/create_directory.html
    You can create a list of files in the directory and read the list files from that directory.
    [UTL_FILE Documentation |http://download.oracle.com/docs/cd/B14117_01/appdev.101/b10802/u_file.htm#996728]
    [Solution using Java|http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:439619916584]
    SS

  • How to create a report  based on selected item from Select list?

    Hi,
    I have created a tables_LOV based on:
    select table_name d, table_name r from user_tab_cols
    where column_name like '%_type%'
    Then I created a page item ListOfTables,  Display as select list and pointing to tables_LOV.
    I run the page, and i can select the table i want from the drop down list.
    How to create a report  based on the selected item? (ex: select * from selected_table)
    many thanks in advance
    Salah

    Hi Salah,
    Allright, have a look at this page: http://apex.oracle.com/pls/apex/f?p=vincentdeelen:collection_report
    I think that simulates what you're trying to accomplish. I've set up the simplest method I could think of.
    The report is based on an apex collection. If you are not familiar with that, you should study the documentation: APEX_COLLECTION
    To recreate my example you should:
    1) create an (interactive) report on your collection
    SELECT *
       FROM APEX_collections
    WHERE collection_name = 'MY_COLLECTION'
    2) create a page_item select list for the tables you want to display (in my case this is called "P38_TABLES" )
    3) create a dynamic action that triggers on change of your select list page_item. The dynamic action must be a PL/SQL procedure perfoming the following code:
    declare
      l_query varchar2(4000);
    begin
      l_query := 'select * from '||:P38_TABLES;
      if apex_collection.collection_exists
            ( p_collection_name => 'MY_COLLECTION' )
      then
        apex_collection.delete_collection
          ( p_collection_name => 'MY_COLLECTION' );
      end if;
      apex_collection.create_collection_from_query
        ( p_collection_name => 'MY_COLLECTION'
        , p_query           => l_query
    end;
    Make sure you add your page_item to the "Page Items to Submit" section.
    4) Add an extra true action that does a refresh of the report region.
    Here are two pictures describing the da:
    http://www.vincentdeelen.com/images/otn/OTN_COLLECTION_REPORT_DA1.png
    http://www.vincentdeelen.com/images/otn/OTN_COLLECTION_REPORT_DA2.png
    Good luck and regards,
    Vincent
    http://vincentdeelen.blogspot.com

  • How to create dynamic context based on a structure defined in the program?

    Hi Experts,
             I need to create a dynamic context based on a structure wa_struc which i have define programatically.
    When I pass wa_struc to structure_name parameter of create_nodeinfo_from_struc, i get a runtime error:
    "Parameter STRUCTURE_NAME contains an invalid value wa_struc."
    How to create dynamic context based on a structure defined in the program?
    I have written the code like this:
    TYPES: BEGIN OF t_type,
                v_carrid TYPE sflight-carrid,
                v_connid TYPE sflight-connid,
             END OF t_type.
      Data:  i_struc type table of t_type,
             wa_struc type t_type.
      data: dyn_node   type ref to if_wd_context_node.
      data: rootnode_info   type ref to if_wd_context_node_info.
      rootnode_info = wd_context->get_node_info( ).
      clear i_struc. refresh i_struc.
      select carrid connid into corresponding fields of table i_struc from sflight where carrid = 'AA'.
    cl_wd_dynamic_tool=>create_nodeinfo_from_struct(
      parent_info = rootnode_info
      node_name = 'dynflight'
      structure_name = 'wa_struc'
      is_multiple = abap_true ).
    dyn_node = wd_context->get_child_node( name = 'dynflight' ).
    dyn_node->bind_table( i_struc ).
    Thanks
    Gopal
    Message was edited by: gopalkrishna baliga

    Hi Michelle,
              First of all Special thanks for your informative answers to my other forum questions. I really appreciate your help.
    Coming back to this question I am still waiting for an answer. Please help. Note that my structure is not in a dictionary.
    I am trying to create a new node. That is
    CONTEXT
    - DYNFLIGHT
    CARRID
    CONNID
    As you see above I am trying to create 'DYNFLIGHT' along with the 2 attributes which are inside this node. The structure of the node that is, no.of attributes may vary based on some condition. Thats why I am trying to create a node dynamically.
    Also I cannot define the structure in the ABAP dictionary because it changes based on condition
    I have updated my code like the following and I am getting error:
    TYPES: BEGIN OF t_type,
    CARRID TYPE sflight-carrid,
    CONNID TYPE sflight-connid,
    END OF t_type.
    Data: i_struc type table of t_type,
    dyn_node type ref to if_wd_context_node,
    rootnode_info type ref to if_wd_context_node_info,
    i_node_att type wdr_context_attr_info_map,
    wa_node_att type line of wdr_context_attr_info_map.
    wa_node_att-name = 'CARRID'.
    wa_node_att-TYPE_NAME = 'SFLIGHT-CARRID'.
    insert wa_node_att into table i_node_att.
    wa_node_att-name = 'CONNID'.
    wa_node_att-TYPE_NAME = 'SFLIGHT-CONNID'.
    insert wa_node_att into table i_node_att.
    clear i_struc. refresh i_struc.
    select carrid connid into corresponding fields of table i_struc from sflight where carrid = 'AA'.
    rootnode_info = wd_context->get_node_info( ).
    rootnode_info->add_new_child_node( name = 'DYNFLIGHT'
    attributes = i_node_att
    is_multiple = abap_true ).
    dyn_node = wd_context->get_child_node( 'DYNFLIGHT' ).
    dyn_node->bind_table( i_struc ).
    l_ref_interfacecontroller->set_data( dyn_node ).
    But now I am getting the following error :
    The following error text was processed in the system PET : Line types of an internal table and a work area not compatible.
    The error occurred on the application server FMSAP995_PET_02 and in the work process 0 .
    The termination type was: RABAX_STATE
    The ABAP call stack was:
    Method: IF_WD_CONTEXT_NODE~GET_STATIC_ATTRIBUTES_TABLE of program CL_WDR_CONTEXT_NODE_VAL=======CP
    Method: GET_REF_TO_TABLE of program CL_SALV_WD_DATA_TABLE=========CP
    Method: EXECUTE of program CL_SALV_WD_SERVICE_MANAGER====CP
    Method: APPLY_SERVICES of program CL_SALV_BS_RESULT_DATA_TABLE==CP
    Method: REFRESH of program CL_SALV_BS_RESULT_DATA_TABLE==CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~MAP_FROM_SOURCE_DATA of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~MAP_FROM_SOURCE of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~UPDATE of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_VIEW~MODIFY of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMPONENT~VIEW_MODIFY of program CL_SALV_WD_A_COMPONENT========CP
    -Gopal
    Message was edited by: gopalkrishna baliga

  • How to create web services in java?

    Hi,
    I am a newbie to java webservices. Can anybody tell me how to create web services in java?
    Any tutorial link or step by step doc would be useful.
    Appreciate your help in this regard.
    Thanks in advance.
    naymo01.

    Creating web services in Java appears to depend highly upon the server you intend to use.
    Here's a tutorial: http://java.sun.com/webservices/docs/1.6/tutorial/doc/index.html

  • How to create Web Service Proxy with help of WSDL.

    Hi ,
    How to create Web Service Proxy with help of WSDL .
    Please help me .
    Thanks in advacne for reply .

    check out this article. It has all the details
    http://www.oracle.com/technology/products/jdev/howtos/1013/wsadf/adfcomplexwstypes.html

Maybe you are looking for

  • Report on another report

    Hi All, I have a table where i am setting active flag for item as 'N' while inserting an item. I am fetching report from that table. There in the report i have edited the column of ACTIVE flag as select list and assigned LOV as yes and no. If i selec

  • SharePoint 2010 Allow User to Add Comments to Files in a Library and to the Header of the Web-Page

    (1) I need to allow an end-user to be able to add comments to files either when they are added to a library or after they are added. I didn't see a Column available for adding to a Document Library for "Comments". (2) I need the same user to be able

  • Https apache not working with IE

    as of a couple patches ago, IE clients stopped being able to access https pages on my server. any attempt to access an https page on my server gives the standard IE "The page cannot be displayed" page. i haven't done anything magical or unusual to my

  • Since the newest hp update, my sound has gone completely silent. any ideas?

    I have an HP Pavilion g6 and I just updated with an unknown update (it doesn't show in my "View History") so I'm not entirely sure which one it was, but since then I've lost my sound completely. I'm about to update my sound driver, but in the mean ti

  • What are the effects in processing office 2007 document filtering in Oracle

    Does any one know what are the effects or changes in Oracle text (9i - 9.2.0.4.0) while handling the MS office 2007 file formats? Does Oracle 10g solves the problem or will there be any patches released for this issue?