How to reference a pre-defined table type in entity definition

I have a Table Type brc.sapere.gso.DDL::domain.TIME_PERIOD defined.
I try to use it in an entity definition. (dbcommon.hdbdd is attached.)
But there is an error saying
ERROR      brc/sapere/gso/DDL/dbcommon.hdbdd
           CDS activation failed;Full qualified names are not allowed
How can I reference the table type?

Kalhari wrote:
Hi, Thanks, but I've seen this. What I need to know is if there is a way to map "user defined table type" specifically, which is a new SQL type introduced with SQL 2008.1. Depends on the database.
2. Depends on the JDBC driver
3. Depends on JDBC spec that it being used.

Similar Messages

  • How to pass a user defined table type to stored procedure?

    Hi,
    I am trying to call a stored procedure from Java. The store procedure has three IN parameter, 2 IN/OUT params and 3 OUT parameters. The two IN/OUT parameters are user defined objects. Can anyone tell me how to set these IN/OUT parameters in Java.
    Thanks

    It is database/driver specific so you need to use the specific functionality of the driver (not jdbc) to access it.

  • How do i declare a user defined table type sproc parameter as a local variable?

    I have a procedure that uses a user defined table type.
    I am trying to redeclare the @accountList parameter into a local variable but it's not working and says that i must declare the scalar variable @accountList.this is the line that is having the issue: must declare the scalar variable @accountListSET @local_accountList = @accountListALTER PROCEDURE [dbo].[sp_DynamicNumberVisits] @accountList AS integer_list_tbltype READONLY
    ,@startDate NVARCHAR(50)
    ,@endDate NVARCHAR(50)
    AS
    BEGIN
    DECLARE @local_accountList AS integer_list_tbltype
    DECLARE @local_startDate AS NVARCHAR(50)
    DECLARE @local_endDate AS NVARCHAR(50)
    SET @local_accountList = @accountList
    SET @local_startDate = @startDate
    SET @local_endDate = @endDate
    CREATE TYPE [dbo].[integer_list_tbltype] AS TABLE(
    [n] [int] NOT NULL,
    PRIMARY KEY CLUSTERED
    [n] ASC
    )WITH (IGNORE_DUP_KEY = OFF)
    GO

    Why are you asking how to be an awful SQL programmer??  Your whole approach to SQL is wrong.
    We have a DATE data type so your insanely long NVARCHAR(50) of Chinese Unicode strings is absurd. Perhaps you can post your careful research on this? Can you post one example of a fifty character date in any language? 
    The use of the "sp_" prefix has special meaning in T-SQL dialect. Good SQL programmers do not use CREATE TYPE for anything. It is dialect and useless. It is how OO programmers fake it in SQL. 
    The design flaw of using a "tbl-" prefix on town names is called "tibbling" and we laugh at it. 
    There are no lists in RDBMS; all values are shown as scalar values. First Normal Form (1NF)? This looks like a set, which would have a name. 
    In any -- repeat any -- declarative programming language, we do not use local variables. You have done nothing right at any level. You need more help than forum kludges. 
    --CELKO-- Books in Celko Series for Morgan-Kaufmann Publishing: Analytics and OLAP in SQL / Data and Databases: Concepts in Practice Data / Measurements and Standards in SQL SQL for Smarties / SQL Programming Style / SQL Puzzles and Answers / Thinking
    in Sets / Trees and Hierarchies in SQL

  • User defined table type output not coming

    hi all,
    i have a userdefined type delcared as:
    create or replace TYPE SAMPLE_SEARCH AS OBJECT (
    -- LIST OF VARIABLE NAMES AND RESPECTIVE DATA TYPE
    i have a user defined table type defined as:
    create or replace TYPE SAMPLE_SEARCH_TABLE IS TABLE OF SAMPLE_SEARCH;
    I have a stored proc which has an output paramter of type SAMPLE_sEARCH_TABLE.
    that is,
    sp_sample_proc(sample_search_tb OUT SAMPLE_SEARCH_TABLE);
    When i invoke the above stored proc from an anonymous pl/sql block , how can i display the contents of the output parameter using dbms_Output statements?

    Try this.........This is just a sample code.
    CREATE OR REPLACE TYPE address1 AS OBJECT
    (country VARCHAR2(1000),
    city VARCHAR2(1000),
    zip NUMBER,
    add1 VARCHAR2(4000),
    add2 VARCHAR2(4000));
    CREATE OR REPLACE TYPE t_addObj IS TABLE OF address1;
    CREATE OR REPLACE PROCEDURE Sp_Address_Obj(Out_Add_Obj OUT t_Addobj) IS
    v_Addobj t_Addobj := t_Addobj();
    BEGIN
    SELECT Address1(u.Object_Name,
    u.Object_Type,
    u.Object_Id,
    'Add01' || Rownum,
    'Add02' || Rownum) BULK COLLECT
    INTO v_Addobj
    FROM User_Objects u;
    Out_Add_Obj := v_Addobj;
    END Sp_Address_Obj;
    DECLARE
    v_Addobj t_Addobj := t_Addobj();
    BEGIN
    Sp_Address_Obj(v_Addobj);
    Dbms_Output.Put_Line(v_Addobj(1).City);
    FOR i IN 1 .. v_Addobj.Count LOOP
    Dbms_Output.Put_Line(v_Addobj(i).Country || '-' ||
    v_Addobj(i).City || '-' ||
    v_Addobj(i).Zip || '-' ||
    v_Addobj(i).Add1 || '-' ||
    v_Addobj(i).Add2);
    END LOOP;
    END;

  • Syntax error when creating a user-defined table type in SQL Server 2012

    Why am I getting a syntax error when creating a user-defined table type in SQL Server 2014?
    CREATE TYPE ReportsTableType AS TABLE 
    ( reportId INT
    , questionId INT
    , questionOrder INT );
    Results:
    Msg 156, Level 15, State 1, Line 1
    Incorrect syntax near the keyword 'AS'.

    Hope these posts could help, 
    https://social.msdn.microsoft.com/Forums/sqlserver/en-US/37a45a9a-ed8c-4655-be93-f6e6d5ef44be/getting-incorrect-syntax-while-creating-a-table-type-in-sql-server-2008-r2?forum=transactsql
    Regards, Dineshkumar,
    Please Mark as Answer if my post answers your question and
    Vote as Helpful if it helps you

  • User defined table types sometimes show up a unknown data type in Profiler

    A couple of our users have a problem when using user defined table types. Calls are made using UDTT as variables and these are then passed to a stored procedure as parameters. Sometimes the application returns a timeout. In such situations a Profiler-Trace
    shows the following:
    declare @p4 unknown
    whereas the correct trace (that is sometimes displayed) should be:
    declare @p4 dbo.ReportFilterTableType
    ReportFilterTableType is a UDTT. The users do have correct permissions for the UDTT (otherwise they would never be usable for the user). What could be the reason that the data types for the variable
    @p4 in the example are sometimes returned as unknown and at other times are returned correctly as
    ReportFilterTableType? Could this possibly be a network related issue?
    Thank you.
    Graham Goodwin Email: [email protected]

    I know this is a old post, but i am also facing the same issue that too in my production server. Did you find any workarround for this issue. Please do reply. Critical problem we are facing.
    Alka, Is your problem timeouts when passing TVP parameters, or is it that a Profiler Trace shows type "unknown" for the TVP data type name?
    If your problem is timeouts, be aware that TVPs do not have statistics so the optimizer might not be able to generate an optimal plan for non-trivial queries. Declaring a primary key or unique constraint on the table type may help since that will provide
    useful cardinality information.  You may need to resort to hints in some cases.
    I suggest you start a new thread with details of your specific situation if the information in this thread doesn't help.
    Dan Guzman, SQL Server MVP, http://www.dbdelta.com

  • User-Defined Table Types - Where is it in SQL Server 2008?

    I am having 2 issues:
    1.  I don't see a folder for 'User-Defined Table Types' under programmability-->Types
    2.  When I execute the following code to create a Type; I get an error 'Incorrect syntax near the keyword 'AS'.'
    USE Locations;
    GO
    /* Create a user-defined table type */
    CREATE TYPE LocationTableType AS TABLE
    ( LocationName VARCHAR(50)
    , CostRate INT );
    GO

    Hi Shayann,
    The  user-defined table type is a new
    feature from SQL Server 2008. If you want to use it you have to upgrade your database to SQL Server 2008 or above.
    In you scenario(SQL Server 2005),as a workaround, you can use the  local temporary table instead. 
    --in SQL Server 2005
    CREATE TABLE tblType(id INT,name VARCHAR(99))
    GO
    CREATE PROC proc1
    AS
    BEGIN
    SELECT * FROM #temp;
    END
    GO
    SELECT * INTO #temp FROM tblType; -- the #temp name is fixed
    INSERT INTO #temp VALUES(1,'Eric');
    EXEC proc1
    --In SQL Server 2008 or above
    CREATE TYPE LocationTableType AS TABLE
    ( id INT,
    name VARCHAR(99) );
    GO
    CREATE PROC proc1 @t LocationTableType READONLY
    AS
    BEGIN
    SELECT * FROM @t
    END
    GO
    DECLARE @t LocationTableType;
    INSERT INTO @t VALUES(1,'Eric');
    EXEC proc1 @t
    I still suggest you upgrade to higher SQL Server.
    If you have any question, feel free to let me know.
    Best regards,
    Eric

  • Pre defined set types are not determined in CAtegory

    Hi all,
    when i try to create a category for a service product for SLA, the pre defined set types are not getting populated for me.
    I have created a new hierarchy, assigned to product and product type.....
    but still when i create a category the list of predefined some of the predefined set types are not getting displayed.
    Can anyone help this issue.
    kindly advice in this regard.
    Thanks,
    Subhashini.

    Hi,
    Thanks for the reply.
    I have assigned the product type service in the category.
    This is the only custom category available. only one std category has this set types. other than that nothing is there in the system.
    is there any services that has to be activated or any authorization that is missing for me...
    nut i have sap_all...could not able to trace out the problem.
    kindly guide.
    thanks,
    Subhashini.

  • Define table type on runtime...Getting Error..

    My requirement is to
    I am trying to define table type on runtime. i.e. ortf_in_table_tbl{noformat}({noformat}i).field_position_rec.ortf_segment_field_name in below code.
    But when I am executing below code and getting below error:
    DECLARE
       CURSOR field_position_cur (p_table_name VARCHAR2)
       IS
          SELECT xosf.field_name, xosf.starting_position, xosf.field_length
            FROM record_types xort, record_segments xors, segment_fields xosf
           WHERE xort.record_type_id = xors.record_type_id
             AND xors.record_segment_id = xosf.record_segment_id
             AND xosf.table_name = p_table_name;
       CURSOR raw_data_cur
       IS
          SELECT *
            FROM raw_data;
       TYPE raw_data_typ IS TABLE OF raw_data_cur%ROWTYPE
          INDEX BY BINARY_INTEGER;
       TYPE table_typ IS TABLE OF emp%ROWTYPE
          INDEX BY BINARY_INTEGER;
       table_tbl      table_typ;
       raw_data_tbl   raw_data_typ;
    BEGIN
       OPEN raw_data_cur;
       LOOP
          FETCH raw_data_cur
          BULK COLLECT INTO raw_data_tbl;
          EXIT WHEN raw_data_tbl.COUNT = 0;
          FOR i IN raw_data_tbl.FIRST .. raw_data_tbl.LAST
          LOOP
             FOR field_position_rec IN field_position_cur ('EMP')
             LOOP
                table_tbl (i).field_position_rec.field_name :=
                   SUBSTR (raw_data_tbl (i).raw_line_text,
                           field_position_rec.starting_position,
                           field_position_rec.field_length
                DBMS_OUTPUT.put_line
                        (   'table_tbl (i).field_position_rec.field_name '
                         || table_tbl (i).field_position_rec.field_name
             END LOOP;
          END LOOP;
       END LOOP;
       CLOSE raw_data_cur;
    FORALL i IN table_tbl.FIRST .. table_tbl.LAST
          INSERT INTO emp
               VALUES (table_tbl (i)
       COMMIT;
    EXCEPTION
       WHEN OTHERS
       THEN
          DBMS_OUTPUT.put_line ('OTHERS ' || SQLERRM);
    END;
    **ORA-06550: line 61, column 52:**
    **PLS-00302: component 'FIELD_POSITION_REC' must be declared**
    **ORA-06550: line 54, column 13:**
    **PL/SQL: Statement ignored**Here field_position_cur is giving me column name for the EMP table (i.e. field_position_rec.field_name) and field_position_cur is giving start and length to derive value of the that column
    i.e.
    SUBSTR (raw_data_tbl (i).raw_line_text,
                           field_position_rec.starting_position,
                           field_position_rec.field_length
                          )But it is giving me error. We are on 10g database.
    Please suggest the solution to it.
    Edited by: BluShadow on 12-Jan-2012 08:21
    added {noformat}{noformat} and other tags to make it readable.  Please read {message:id=9360002} and learn to do this yourself.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    piyushgupta wrote:
    My requirement is to
    I am trying to define table type on runtime. Please explain - it is not clear from the code what you are attempting.
    Also note that PL/SQL is strong typed language. This mean that you cannot define a variable using a weak type and at runtime change that into a formal data type.
    In Oracle, the abstract AnyData data type can be used for unknown data types - and methods exist that allows different data types to be stored and retrieved as AnyData types. Of course, there are overheads involved in using an abstract data type (implemented as an object class) like this.
    Another method is to use DBMS_SQL to create dynamic code (SQL or PL/SQL) - and perform dynamic binding (the bind determines the data type of the bind variable in the code). If the dynamic code is a SQL select, the describe interface enables you to determine the content (columns and data types) of the SQL projection.
    The final method that comes to mind is using a RTTI (Run Time Type Information) interface - something that is also supported by Oracle (and basically the backend implementation of answering a describe interface call). This is however a bit more complex and quite specialised and needs a very unique problem to justify it being used.

  • Can i return a SYS_REFCURSOR from a programmer defined TABLE type in a fn?

    Good morning,
    I have a function that i declared a record type, and corresponding table type for that record in.
    Throughout my function , i populate my record type, then add the record to the table.
    At the end of my function, i'd like to return a sys_refcursor to my table.
    is that possible?
    everything seems to work up until i try to create a cursor from the table. my records populate the table successfully, and i can use a for loop at the end of my fn() to iterate through the table and echo out my data to dbms_output. what i'd like to do instead, is pass a cursor to my table to the caller of the function.
    works:
    FOR i IN t_my_tab.FIRST .. t_my_tab.LAST
    LOOP
    DBMS_OUTPUT.put_line('record: ' || t_my_tab(i).fieldname);
    END LOOP;
    doesn't work:
    OPEN my_cur FOR select fieldname from t_my_tab;
    RETURN my_cur;

    Bad idea.
    Why? Because this so-called "table" is in fact a PL/SQL array. It resides in the PGA - dedicated memory belonging to the Oracle process running the PL/SQL code.
    Now you want to open a refcursor against it - this only works against SQL data. So the data needs to be shipped from the PL/SQL engine to the SQL engine. Then a cursor needs to be created against the temporary set of data in memory.
    This is slow. This is cumbersome. The SQL Engine's "temporary data" structure is called a global temporary table. This is a proper SQL table - not a very simplistic array structure that has to be twisted into looking like a SQL table. It already resides in the SQL engine.
    The best place for data in Oracle is in a SQL table.
    So why then use PL/SQL arrays? For the same reason as you would use them in Pascal, C/C++, Java, Visual Basic, Cobol, Fortran, etc. Dealing with local program specific data and data structures - not as a stand-in for a SQL table.
    And as soon as you contemplate running a SQL against a PL/SQL array, you must ask yourself if this is the correct thing to do. 99% of the time, the answer will be "No. This is the Wrong Thing to Do".

  • How to handle plsql Object and Table type inside BPEL

    Hi All,
    I have a procedure with 5 IN and 4 OUT parameters. Out of 4, One is Object type and remaining 3 are Table type. Now in my bpel, i am calling this proc from DB Adapter. The DB Adapter wizard created XSD with proper structure. But when i am testing this i am not getting these out parameters values in the payload of Invoke DBAdapter activity. I am neither getting errors nor output.
    What could be the issue.?
    Thanks in advance,
    Sudheer

    Arik,
    JDev is not creating any wrapper packages as such. It simply created a XSD with same as my procedure name.
    My XSD looks like this...
    <element name="OutputParameters">
    <complexType>
    <sequence>
    <element name="P_OBJ_H_INFO_O" type="db:APPS.H_OBJ_TYPE" db:index="6" db:type="Struct" minOccurs="0" nillable="true"/>
    <element name="P_TAB_L_INFO_O" type="db:APPS.L_TAB_TYPE" db:index="7" db:type="Array" minOccurs="0" nillable="true"/>
    <element name="P_TAB_M_INFO_O" type="db:APPS.M_TAB_TYPE" db:index="8" db:type="Array" minOccurs="0" nillable="true"/>
    <element name="P_TAB_A_INFO_O" type="db:APPS.A_TAB_TYPE" db:index="9" db:type="Array" minOccurs="0" nillable="true"/>
    </sequence>
    </complexType>
    </element>
    And again the 3 table types internally referring object types.
    Thanks for reply. Awaiting response...
    Sudheer

  • How to build secondary keys dynamicaly in a generic entity definition class

    Hi developers,
    try to rebuild a generic entity definition class, where every instanced entity typ can has its own set of secondary fields. On the first moment it seems to be no problem, but now my problem is how to bind the annontation @Secondarykey... to the particular fields during construction of the entity shell be used?
    Hope I counld make the problem visible?
    Thanks for any help!
    ApeVeloce

    Hi Joachim,
    After understanding more about your application (off forum) I think I can answer your question more clearly. The general problem is: How can a dynamic, user defined schema be represented in Berkeley DB for multiple entity types, each with any number of properties, and arbitrary secondary keys for selected properties?
    There are many ways to do this and I'll describe one approach. I do not recommend using DPL for this case. In our documentation,
    http://www.oracle.com/technology/documentation/berkeley-db/je/PersistenceAPI/introduction.html
    we say: "Note that we recommend you use the DPL if all you want to do is make classes with a relatively static schema to be persistent." For a dynamic schema that is not represented using Java classes, the base API provides more flexibility.
    The common requirements for a dynamic schema are:
    1) Each entity has a type, which is roughly equivalent to a Java class. But unlike classes, types may be added dynamically. Queries are normally limited to entities of a particular type; this is not true for all applications, but I will make this assumption here.
    2) Each entity contains, at least logically, a Map of key-value properties. The property name is equivalent to a Java field name and the property value is equivalent to the field value. Properties may be added dynamically.
    3) Any number of properties for a given type may be defined as secondary keys. Secondary keys may be added dynamically.
    One approach for implementing this is as follows.
    A) A Database per entity type is created. This allows queries against a given type to be performed withing a single database. For simplicity the database name can be set to the name of entity type.
    The alternative is to have a single Database for all entity types. This works well for applications that want to query against properties that are common to all entity types. While such a schema is not common, it does occur; for example, an LDAP schema has this characteristic. If you do store all types in a single Database, and you want to query against a single entity type, you'll need to make the entity type a secondary key and perform a BDB "join" (see Database.join) that includes the type key.
    When queries are performed against a single type it is more efficient to have a Database per type. This avoids the extra secondary key for entity type, and the overhead of using it in each query.
    Another advantage to using a Database per type is that you can remove the entire Database in one step if the type is deleted. Calling Environment.removeDatabase is more efficient than removing the individual records.
    B) The properties for each entity can be stored as serialized key-value pairs. There are several ways to do this, but they are all roughly equivalent:
    B-1) If you use a SerialBinding, Java serialization does the work for you, but Java serialization produce larger data and is slower than using a TupleBinding.
    B-2) A TupleBinding can be implemented to write the key-value pairs. Each key is the string name. The value can also be a String, if all your data values are already Strings or if you convert values to/from Strings when they are used.
    B-3) If you have typed values (the type of each property is known) and you don't want to store values as Strings, you can write each value as a particular type in your TupleBinding. See TupleInput and TupleOutput for details.
    If your property values are not simple types (String, Integer, etc) then this approach is more complex. When using a TupleBinding, you will need custom marshaling code for each complex type. If this is too complex, then consider using a SerialBinding. Java serialization will handle arbitrary complex types, as long as each type is serializable.
    Another approach is to store each property in record of its own in a Properties database. This is a natural idea to consider, because this is what you might do with a relational database. But I do not recommend this approach because it will be inefficient to reconstruct the entire entity record from the individual property records. With BDB, we are not limited to the relational model so we can store the entire key-value map easily in a single record.
    However, this is one advantage to using a Properties database: If you commonly add or remove a single property, and entities normally have a large number of properties, and you do not commonly reconstruct the entire entity (all properties), then the Properties database approach may be more efficient. I do not think this is common, so I won't describe this approach in detail.
    C) To support any number of secondary keys, you will need to know which properties are secondary keys and you will need to implement the SecondaryKeyCreator or SecondaryMultiKeyCreator interface.
    C-1) Assuming that you have a Database per entity type, the simplest approach is to create a single SecondaryDatabase for each entity type that is associated with the primary Database for that type. The name of the SecondaryDatabase could be the name of the primary Database with a special suffix added.
    In this case, you should implement SecondaryMultiKeyCreator that returns all secondary key properties for a given entity. A two-part key should be returned for each property that is a secondary key -- {name, value} -- where name is property name and value is the value (either as a String or as a binary type using TupleInput/TupleOutput). When you perform queries for a given property, you will need to construct the {name, value} key to do the query.
    The SecondaryDatabase will need to permit duplicates (see SecondaryConfig.setSortedDuplicates) to allow any of the secondary keys to have the same value for more than one entity. If you have secondary keys that are defined to be unique (only one value per entity) then you will need to enforce that restriction yourself by performing a lookup.
    C-2) The alternative is to create a SecondaryDatabase for every property that is a secondary key. The database name could be the primary database name with a suffix identifying the secondary key.
    In this case you can implement either SecondaryKeyCreator or SecondaryMultiKeyCreator, depending on whether multiple values for each secondary key are permitted. And you can configure duplicates for the secondary database only if more than one entity may have the same secondary key value.
    Each secondary key consists only of its value, the name is not included because it is implied by the SecondaryDatabase in which it is stored. This approach is therefore more efficient than C-1 where we have a single SecondaryDatabase for all properties, because the secondary keys are smaller. However, there is the added work of maintaining the SecondaryDatabases each time the schema is changed: You must create and remove the secondary databases as the schema changes.
    For best performance, I recommend C-2.
    D) If you have a dynamic schema, you must store your metadata: the information that describes the names of each entity type, the properties allowed for that type (if restricted), and the list of which properties are secondary keys.
    I recommend storing metadata in a Database rather than in a file. This database could have a special name that cannot be used for any entity type. When metadata changes, you will be adding and removing databases. To ensure consistency, you should change the metadata and change the databases in a single transaction. This is possible only if you store the metadata in a Database.
    The Berkeley DB base API provides the flexibility to implement a dynamic schema in a very efficient manner. But be warned that implementing a data store with a dynamic schema is a complex task. As requirements grow over time, the metadata becomes more complex. You may even have to support evolution of metadata. If possible, try to keeps things as simple as possible.
    If you want complete flexibility in your schema and/or you want to store complex data types, you may want to consider storing XML. This is possible with Berkeley DB Java Edition since you can store arbitrary data in a Database, but you must implement secondary indexes for the XML data yourself -- this could be a very complex task. If you don't require pure Java, you should consider the Berkeley DB XML product. BDB XML supports many kinds of indexes as well as large documents, XPath, XQuery, and other features.
    Mark

  • How to fill pre-defined tables in Word 2003 with test results?

    Hi All,
    I have a simple test board , where i measure different DC levels,  with a simple Vi that saves the test results in to a Text file.
    These results in text file, were manually typed in to a test report , which is a Word document with tables, but i have now created a macro in word 2003 that can take the results from text file and added to the specific rows and columns in  my word test report file.
    The big questions is how can i get Labview to,after it has measured the DC levels, write the test results to the specific tables , rows and columns, in the Word document without deleting all?
    The attached picture illustrates one tables , and the yellow cells showing the cells that need to be filled in with test results.
    Labview vers: 2009
    Solved!
    Go to Solution.
    Attachments:
    Template.jpg ‏37 KB

    Hi!
    I'm a Test Engineer for electronics and I create alot of automated tests with LabVIEW. Many of our customers want testsresults in a fancy and easy-to-read report. I did not have the MS Office Report Generation tool. So I did some research in the Excel Board and came a cross a link to a free open Excel toolkit ( Link ). The toolkit looks like this in LabVIEW:
    As you can see, you have many tools to get the job done. I'm talking about reading, writing and formatting Excel. The toolkit uses activeX. If you give me a few minutes I'll create an example for you.
    What I do when I create a report:
    Step 1. Create a template with all your formatting, macros, images and colors. Name the file for example "template.xlsx" (or .xls if you use an older office version).
    Step 2. In your program, copy the file to the desired location and give it a proper name.
    Step 3. Aquire some data and write it to the file you copied and renamed.
    For my latest project I created a fully-automated testprogram for testing a electric product. After each test a report is generated based on the procedure above. After testing all the products I have for example 300 reports. I then created a program that reads all the reports and creates a summary report that contains statistics for all the tested products. In my program I can also print the reports or the summary report and deliver to our customer. All this takes just a few seconds and adds extra quality to the products we sell to our customer.
    Regards,
    Even
    Certified LabVIEW Associate Developer
    Automated Test Developer
    Topro AS
    Norway

  • Inbound Processing with reference to user defined Message type

    Respected Readers,
    I have created a segment with fields
    Matnr
    mbrsh
    mtart
    vpsta
    maktx
    meins
    matkl(Total 7 fields)
    I have created a idoc also and a message type and assign the idoc with message type.
    Now i have set the communication partners also and created the distribution model with my message type and distributed also to the reciver side.
    Now as it is not the standard message type like MATMAS so we cannot use the tcode BD10 to send the material.Instead of it i have to write the program to create the idoc for sending it.
    So i have created the program for the generation of IDOC.
    Upto here picture is clear.
    In the case of Inbound in standard we use the tcode BD11 to get material but same thing as we are not using the Standard Message type we have to create our program.
    Now in this case i have written a function module and that function module is attached to the process code and process code is attached to the message type and message type is attached to the partner profile.
    i have done the assignments in we57 and bd51 also.
    Now idoc is created in the inbound side with status 70.
    but i am not getting how to upload this data in standard tables Mara and Makt.
    So that if i go to tcode MM02 and give the respective Matnr ,it should display that material.
    First tell me what i have done is the right procedure or i have to make somechanges somewhere .
    Secondly if you please give me the function module code for inbound processing to upload the data in this standard table( mara ,makt)  so that material is created in the reciver side also.i will be very thankful to you.
    I am only using seven fields in creating the material.
    Please kindly send your answers and not links .
    Thanks

    i have done the same thing and used same parameter in import ,export ,tables and exception tab.
    i have written some code also .
    But i am not getting the code to upload the data in the standard tables so that material should be get created automatically as soon as the data get uploaded
    in tables.
    Somewhere i have read that you have to use the BDC concept Call transaction method to upload the data.
    But how to use the BDC code in  Function module , i am not getting.
    Please can you send any example of code for this task.

  • How to assign values into nested table type in plsql

    hi all,
    I feel some what difficult to return user defined types from plsql function and procedures .
    Can any one help me to learn this .
    Version details are as follow
    BANNER
    Oracle Database 10g Express Edition Release 10.2.0.1.0 - Product
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for 32-bit Windows: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    SQL>
    create or replace type emp_names_nt is table of varchar2(100);
    /* Formatted on 2012/04/05 15:23 (Formatter Plus v4.8.8) */
    CREATE OR REPLACE FUNCTION get_emp_names
       RETURN emp_names_nt
    IS
       CURSOR ec
       IS
          SELECT ename
            FROM emp;
       v_emp_names   emp_names_nt := emp_names_nt ();
    BEGIN
       FOR i IN ec
       LOOP
          v_emp_names.EXTEND ();
          v_emp_names (i) := i.ename;
       END LOOP;
       RETURN v_emp_names;
    END;
    Error :
    PL/SQL: Statement ignored
    PLS-00382: expression is of wrong typeThanks in advance .............
    Thanks,
    P Prakash

    CREATE OR REPLACE FUNCTION get_emp_names
       RETURN emp_names_nt
    IS
       CURSOR ec
       IS
          SELECT ename
            FROM scott.emp;
       v_emp_names   emp_names_nt := emp_names_nt();
       cnt  number:=1;
    BEGIN
       FOR i IN ec
       LOOP
          v_emp_names.EXTEND;
          v_emp_names(cnt) := i.ename;
          cnt:=cnt+1;
       END LOOP;
       RETURN v_emp_names;
    END;
    show errors

Maybe you are looking for

  • Lines appear under all text when you press enter--edit?

    Hello, I have a text box, whose formatting I want to edit. When you press enter a horizontal line appears automatically before you enter in text on the new line. I want to edit this line so it is closer to the text. Where do I go to edit this feature

  • Making a color transparent in many layers

    I'm using Photoshop Elements 5.0 I want to create an animated gif using many layers of jpegs. Each layer is a picture of the earth (round) surrounded by the color black to the edge of the jpeg (square). However, I would like to make the outer border

  • Incorrect phone number on Voice Message alert

    I'm a newbie here, so please be patient. I received an email alert saying that I had a new voice message. It said, "left by ...+****************" Obviously, I noticed the number was odd, but I was able to listen to the voice message OK. However, I ca

  • CAN I KNOW THE BETTER COMBINATION FOR IMPLEMENTAION

    Hi Can u please give the better combination for implentaion of RAC with versions: ex Oracle10g R2+HPUX11iv3+oracle custer ware R2 Thanks & Regards, Naren Jerry ORACLE DBA CONSULTANT

  • IOS 6 locked me out of ipad2 . Won't accept my pass code

    I upgraded my ipad2 to ios6 last night. This morning I go to my iPad and it has grey screen with IOS 6 on it. I try to unlock it and it does not accep my pass code. Please help.