Database View used in Reference variable

KGDev
Tera Contributor

Hello community,


I'd appreciate your thoughts on using a database view as the table reference in a Reference variable in the Service Catalog. According to the documentation, database views are typically used for reporting purposes. So, would it be considered bad practice to use them for other purposes? Are there any potential performance issues associated with using a database view in a reference variable?

 

We've had to use a database view to meet the requirement of displaying a column from an extended table that was not accessible in the base table. We successfully displayed that column using the ref_ac_column variable attribute and haven't experienced any performance issues. However, we're concerned because the documentation only mentioned that database views are for reports, so using them in another way might not be recommended.

1 REPLY 1

Mark Manders
Mega Patron

Using too many can be bad, performance wise. You will also run into issues like 'display value'. I have seen database views going over 5 or 6 tables. 

It is not a new table you are creating and you can't apply logic to it, so yes, it is mainly used for reporting (although dot walking and related list conditions have made them less necessary). 

In your use case I think the question is: why isn't this field on the base table if you need to see it there? Because it won't be available for lots of records that are on the base table, or other extended tables and could cause issues when running queries/creating filters.


Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark