Thanks so much Nixon, I understand what you say and I used exactly the workaround you proposed but from my point of view (maybe because I am an old C programmer) there is a big difference between a type that is an enumerator and an integer (or a string ) which can take only one of a defined number of values. Consider my case: I have to describe an attribute that only takes the values "30", "31", "32". The attribute is a string but, due to this limit of Atlas, I will be forced to type it to an enum. So, for example, a program that will read Atlas and define a table on an rdbms will only define the type of that attribute as an integer and not a string.
Regards Diego On Wed, Dec 12, 2018 at 1:52 PM Nixon Rodrigues < [email protected]> wrote: > Deigo, > > You can follow the default types model available in Atlas to know more > about defining ENUM and adding it as a constraint in other types.. > > > https://github.com/apache/atlas/blob/master/addons/models/1000-Hadoop/1030-hive_model.json > > Here *hive_principal_type* defined is as an ENUM and same is added as a > constraint in hive_db > <https://github.com/apache/atlas/blob/master/addons/models/1000-Hadoop/1030-hive_model.json#L451> > type for owner attribute. > > Regards > Nixon > > > On Wed, Dec 12, 2018 at 5:47 PM Diego Monetti <[email protected]> wrote: > >> Hi, >> I'm new to Atlas and probably I'm not able to navigate the documentation >> well enough. >> My first problem, of a long sequence, is that I would like to define an >> integer type that takes only one of possible values. I know I could do this >> by defining a specific enum type. But is there a more appropriate way to do >> this via, for example, a constraint? >> >> Diego >> >
