1 Reply Latest reply on Nov 2, 2016 1:07 PM by shawkins

    Teiid virtual view Numeric columns

    hend.amin

      Hello,

      I want to create one virtual view that uses the same tables from different DBs.

      My problem is with the numeric columns, each DB returns different type for the same column.

       

      for example this view:

      CREATE VIEW test_view(

        column_id bigdecimal

        )

        AS(

        select

        column_id

        FROM test

        );

       

      when i deploy the VDB and the Data source is oracle it is ok, for MSSQL or DB2 for example, it throws an exception that the expected type is bigdecimal and the actual was long. It would save me alot of effort if i have one type for whole numbers. Is there some kind of manipulation i can do in the VDB to achieve this. i want something like:

       

      CREATE VIEW test_view(

        column_id number

        )

        AS(

        select

        column_id

        FROM test

        );

       

      So that it would work for all DBs whole numbers types.

       

      Thanks

      Hend