CMDBuild Forum

Meaning of "status" field in raw tables.

Hello,

 
I'm trying to create a history report, and I'm not sure about the meaning of certain fields on these tables.
 
Status
  So far I see "A", "N", and "U"
 
BeginDate and EndDate
  What exactly do these timestamps refer to?
 
Or Is there a guide out there that specifies how the tables are structured?
 
Thanks,
Devin

In CMDBuild each card has one current instance (stored in the base table, status = A’ if it is active or status = N’ if it is deleted) and zero or more historical instances (stored in the _history” table, status = U’).
In each card instance BeginDate is the validity start date, EndDate is the validity end date.
CMDBuild Team

Hy
Some time I have to delete a reference attribute and I can not do it if I do not delete records by hand those cards with states U and N. That is correct.
There is anyway to delete all recors with state U and N? It is advisable ?
 
Previously Tecnoteca wrote:
In CMDBuild each card has one current instance (stored in the base table, status = 'A' if it is active or status = 'N' if it is deleted) and zero or more historical instances (stored in the "_history" table, status = 'U').
In each card instance BeginDate is the validity start date, EndDate is the validity end date.
CMDBuild Team

 

 
You can do this only by working directly on the database via SQL.
For example, you can delete all historical records (Status = "U") of a class "XX" with the SQL command <Truncate table "XX_history";>
But this is dangerous because you lose consistency with the
historical data in the relation tables "Map_YY", if there are reference attributes in that class, and also because if you make mistakes then the database is no longer usable.
CMDBuild Team
Thanks for the answer.
Would be nice to add a feature that allows delete these records or a feature that allows to define the number of days of historical data.
Regards from Argentina
 
Previously Tecnoteca wrote:
 
You can do this only by working directly on the database via SQL.
For example, you can delete all historical records (Status = "U") of a class "XX" with the SQL command <Truncate table "XX_history";>
But this is dangerous because you lose consistency with the
historical data in the relation tables "Map_YY", if there are reference attributes in that class, and also because if you make mistakes then the database is no longer usable.
CMDBuild Team