Skip to Content
0
Jul 28, 2020 at 03:56 AM

HANA dat modeling - View for Querying Records that have tags across multiple categories

46 Views

I have a table that stores different software services a company offer. The services are tagged by the Industry it serves, the LoB it belong to, and the technology involved in the service . The service can have multiple tags on each of Industry,LOB and Technology. For eg: Following could be the master data:

And a transaction data could look like this :

I need to create a view that can be used to query data by Industry/LoB and Technology tags. For time being I've Left outer joined all tagtoService relation tables(service-technology, service-LoB,Service-Industry tables) to the services transaction table. But this goes for a huge number of records as it is possible to typically have one service tagged to upto 10-15 industries and technologies.

Just wanted to know what is the optimal way to model this data so that i have provision to query for a service by all of the three tags right from within one view.

I use HANA HDI container in a CAP application and this view is to be exposed by an odata service to use in UI5 where the tag filtered will be applied and passed for query.