on 10-31-2014 3:05 AM
Hi All
I was trying to gather the data type information using Script
For Each d In model.Domains
Debug.Print d.Name
Debug.Print d.DataType
Next
Shows the below results
Name
A30
Short description
A80
Identifier
N5
Money
MN8,2
Phone
A12
I could not get the data type information properly ( I am not sure what A30, N5 etc ). Can you please guide me to get the proper value for data types. Appreciate your help
Ani
These are internal"abstract" Datatype which will translated at generation time or at displaytime to the choosen DBMS Datatype, when you are in a PDM, i a CDM they are they are the primary datatypes, thought.
see some tables as an example to understand the concept:
from MSQL to internal:
and Internal to Postgres:
A is Alpha and will translatet to CHar, Varchar or whatever TargetDB understands, MN is Money and will be traslated to Mony, or it TargetDB does not have Moneytype to decimal or somehow.
running your script on MSSQL target gives this:
VB Script started on 31.10.2014 at 09:45:51
Domain_1
BINARY LARGE OBJECT
Domain_2
CHAR(5)
VB Script terminated on 31.10.2014 at 09:45:51.
on ANSI level2 gives this :
VB Script started on 31.10.2014 at 09:49:33
Domain_1
CHAR(254)
Domain_2
CHAR(5)
VB Script terminated on 31.10.2014 at 09:49:33.
and in a cdm gives this:
VB Script started on 31.10.2014 at 09:52:00
Domain_1
BL
Domain_2
A5
VB Script terminated on 31.10.2014 at 09:52:00.
HTH
dj
Message was edited by: dirk jaeckel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
dj
Thanks for the reply. I tried the script in LDM , while running the script it shows A30 etc . But when I opened the domain dialogue , It shows the correct datatypes So I am not how it translate it correctly when we open the domain list in the tool.
BTW do you have any clue which object m,PD store all the data types.
Ani
LDM is like CDM independent from Physics, the other part of your question i dont understand.
you can try domain.preview to translate the datatype:
Preview As String | Get Code Preview. This attribute contains a preview of what would be |
if you dont see the code then, you have to change generation settings swich generation of domains on
HTH
dj
User | Count |
---|---|
90 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.