Hi all,
I'm trying write a mapping file to my schema but I not kwnow as... see:
############### class definitions #############
public enum MediaPosition { Master, Slave }
public enum MediaType { Hard, CD, DVD }
public class Media
{
//...
public int ID { ... }
public string Label { ... }
public MediaType Type { ... }
public MediaPosition Position { ... }
//...
}
############### database schema #############
TAB_MEDIA
-----------------
id int,
label varchar(25),
type varchar(2),
position varchar(2)
TAB_DOMAIN
-----------------
field varchar(20),
code varchar(2),
text varchar(40)
############### rows samples #############
TAB_MEDIA
----------------------------------------------------
ID LABEL TYPE POSITION
----------------------------------------------------
0 'MED_00001' '01' '01'
1 'MED_00002' '01' '01'
2 'MED_00003' '02' '02'
3 'MED_00004' '03' '01'
4 'MED_00005' '03' '02'
5 'MED_00006' '01' '02'
TAB_DOMAIN
--------------------------------------------------------------
FIELD CODE TEXT
--------------------------------------------------------------
'Position' '01' 'Media in marter position'
'Position' '02' 'Media in slave position'
'Type' '01' 'Hard disk drive'
'Type' '02' 'CD-ROM drive'
'Type' '03' 'DVD-ROM drive'
Is possible mapping this structure?
Thank's in advice by help...
[]'s
FernandoVM
|