Database view on extended tables

sowmyaj
Giga Expert

Hi All,

                            I have a requirement to create database view on two tables. In which one table is extended from some other table and the other is not. I also read "Rotated and extended tables cannot be included in a database view. Also, an existing database view cannot be a component of another database view".

So need to know any other way to combine the tables and write a query on it. Also, need to know other possibilities of joins like union, intersection etc. except left join.

Thanks,

Sowmya

8 REPLIES 8

sergiu_panaite
ServiceNow Employee
ServiceNow Employee

Hi Sowmya,



The phrase "Rotated and extended tables cannot be included in a database view. " refers to tables present under "Table Rotation" menu (tables that can be of type: rotated/extended). This doesn't mean you cannot create a database view on an extended table as like task->incident or task->change_request. This is still possible.



Can you try it out and let me know if it doesn't work?



Regards,


Sergiu


Hi Sergiu,


       


      I tried left join on the tables Skill(name:cmn_skill) -> Application File and User Skill(name:sys_user_has_skill). I'm not getting the correct result as left join is not working on these tables.



databaseview_with extended.png


                 


        I also tried with the tables which are not extended from any other tables. For these type of tables I'm getting the correct result.


database.png



Thanks,


Sowmya


Kalaiarasan Pus
Giga Sage

Also change the order to 100 and 200 and change the condition as


usr_skill=cmns_name



Make sure that the field types are compatible ..