Salta ai contenuti. | Salta alla navigazione

Sezioni

Forum

Un luogo per gli utilizzatori di CMDBuild. Consigli e suggerimenti, modelli di integrazione e sviluppo.

Chiedi agli esperti

Richiedi il supporto e l'assistenza professionale del maintainer del progetto. Training personalizzati e sviluppo estensioni funzionali.

Azioni sul documento

Looking for tutorial on setting up domains

Tu sei qui: Home Supporto Forum Forum in English Looking for tutorial on setting up domains
Vai al livello superiore

Looking for tutorial on setting up domains

Lasciato da Mark il 29 settembre 2011 alle 0:25

I have two classes, each with a column that is an ip address.  I would like to create an association between these classes, on those two column, but I can't find a simple description on how to do it.  It seems it has to do with domains, but I'm not clear on how to set up the domain, whether I need to set up the domain first, if there's anything special I need to do to set up the columns, etc.

 

TIA

Mark

Re: Looking for tutorial on setting up domains

Lasciato da Tecnoteca il 30 settembre 2011 alle 10:21
In CMDBuild the associations ("domains") can be created between two "classes", not between two "attributes" (as the foreign keys in a relational database)

.

Then, if the domain cardinality is 1:N, in the second class (the one on the "N" side) you can create an "attribute" based on that "domain" (an "attribute" with type "reference")

.

If the cardinality is N:N, relations can be viewed and managed only using the Relations

TAB.

 

Example

------------

Class 1: Supplier

- Code (string)

- Name (string)

- Type (lookup)

- Address (string)

- Email (string)

- etc

 

Class 2: SupplierContact

- Surname (string)

- Name (string)

- Supplier (reference, this attribute must be created after creating the "SupplierToSupplierContact" domain

)

- Phone (string)

 

Domain SupplierToSupplierContact (must be created after creating the

classes "Supplier" and "SupplierContact")

- Origin: Supplier

- Destination: SupplierContact

- Description direct: has contacts

- Description inverse: belongs to supplier

- Cardinality: 1:N

 

So, to sum up:

1) create "Supplier" class

2) create "SupplierContact" class (without the attribute "Supplier")

3) create the domain "SupplierToSupplierContact"

4) add attribute "Supplier" to the "SupplierContact" using the "SupplierToSupplierContact" domain

 

 

Please note that, starting from the latest 1.4 version, CMDBuild can also create and manage specific domain attributes

.

 

For more informations take a look at the manuals (administration and user manuals)

:

    http://www.cmdbuild.org/documentation/manuals?set_language=en&cl=en

 

 

Fabio

 

Re: Looking for tutorial on setting up domains

Lasciato da Mark il 4 ottobre 2011 alle 1:44
Thank you very much.

  That helps a lot :)

 

Re: Looking for tutorial on setting up domains

Lasciato da NOLLET il 20 ottobre 2011 alle 16:26

OK I begin to understand about Domains.

In my case, I have a server description class  including "Operating systems version" attribute

I want to view a relation graph between OS =(1:N)=> Server.

So I have create a "Operating Systems" class including "Operating systems version" attribute

My question is on the domain (OS_Server) creation, how can we configure an automatic creation ?

May I create the relation on each server from my "Server Class" ? In this case, it should be crazily un-usable...

 

Previously Mark wrote:

Thank you very much.

  That helps a lot :)

 

 

Re: Looking for tutorial on setting up domains

Lasciato da NOLLET il 25 ottobre 2011 alle 16:58

Hi,

no way to get this automatically or by import ?

Thanks ?

 

 

Previously NOLLET wrote:

OK I begin to understand about Domains.

In my case, I have a server description class  including "Operating systems version" attribute

I want to view a relation graph between OS =(1:N)=> Server.

So I have create a "Operating Systems" class including "Operating systems version" attribute

My question is on the domain (OS_Server) creation, how can we configure an automatic creation ?

May I create the relation on each server from my "Server Class" ? In this case, it should be crazily un-usable...

 

Previously Mark wrote:

Thank you very much.

  That helps a lot :)

 

 

 

Re: Looking for tutorial on setting up domains

Lasciato da Tecnoteca il 25 ottobre 2011 alle 17:30

Since the domain is 1:N, you might create a reference attribute in Server over the domain with the server class. The result would be to have in the Server form a combo box with all operating systems (the Description attribute). Every time you change a reference attribute, the relation is changed accordingly and vice versa.

If you don't need the OS to be a class (e.g. you just want to use it as an attribute of Server and maybe other classes), you can use a simple lookup attribute (multilevel lookups come in handy to specify OS / Version using two combo boxes).

In both ways you can use the import CSV to fill the information. Please note that references are looked up by the Code attribute while importing.

Hope it helps.

Paolo

 

Re: Looking for tutorial on setting up domains

Lasciato da NOLLET il 25 ottobre 2011 alle 18:21

Sorry I do not understand how to create a reference attribute.

I want to import a long listing detailed of server ( including serverName, OSName,OSVersion,Exploit, IPAdress,IPSave ....)

I want to view relation 1:N from OSName:Server and relation 1:N from Exploit:Server.

To do this, I create a list of unique OSName as a class and a list of unique Exploit as a class.

And now ???

 

 

Previously Tecnoteca wrote:

Since the domain is 1:N, you might create a reference attribute in Server over the domain with the server class. The result would be to have in the Server form a combo box with all operating systems (the Description attribute). Every time you change a reference attribute, the relation is changed accordingly and vice versa.

If you don't need the OS to be a class (e.g. you just want to use it as an attribute of Server and maybe other classes), you can use a simple lookup attribute (multilevel lookups come in handy to specify OS / Version using two combo boxes).

In both ways you can use the import CSV to fill the information. Please note that references are looked up by the Code attribute while importing.

Hope it helps.

Paolo

 

 

Re: Looking for tutorial on setting up domains

Lasciato da Tecnoteca il 26 ottobre 2011 alle 10:1

Sorry I do not understand how to create a reference attribute.

Have you tried looking at the Data Modeling Tutorial?
 
http://www.tecnoteca.tv/cmdbuild/english/data-modeling-cmdbuild-tutorial

Or you could take a look at the demo database. There are several reference attributes defined, in Server as well as in other classes. 

I want to import a long listing detailed of server ( including serverName, OSName,OSVersion,Exploit, IPAdress,IPSave ....)

This is a totally different matter altogether. You have to use the CSV import or setup a connector, that will sync CMDBuild with other sources (relational DBs, an LDAP directories, etc.).

 

Paolo

 

Sviluppato da Ploneboard
Tecnoteca

Tecnoteca ha progettato e realizzato CMDBuild ed è maintainer del progetto.

 

Per contatti:
Tecnoteca srl
Via L'Aquila 1/B
33010 Tavagnacco UD
tel. 0432.689094  
fax 0432.689572
modulo contatti

Partecipa
Twitter LinkedIn Google+ RSS YouTube SlideShare