Problem ATL [message #988633] |
Fri, 30 November 2012 18:49 |
Rafael Durelli Messages: 72 Registered: September 2012 |
Member |
|
|
Hello guys, i'm new at ATL and I'm trying to create a simple transformation that transform a SQLMODEL, which I've devised, to a KDMSQL, which correspond to a extension to the KDM to model SQL statements. However, when I have to create the Datatype I always get an exception. Please, see the code below
-- @path MM=/SQLMODEL/model/sqlmodel.ecore
-- @path MM1=/KDMSQLExtesion/model/kdmSQL.ecore
module transformation;
create OUT : MM1 from IN : MM;
rule table2TableUnit {
from
table : MM!Table
to
tableUnit : MM1!TableUnit (
name <- table.name,
codeElement <- table.columns
)
}
rule column2ColumnUnit {
from
column : MM!Column
to
columnUnit : MM1!ColumnUnit (
name <- column.name,
type <- column.type //the error of Casting is happing here.
//type is Datatype and column.type is a String, how can I create a Datatype correctly?
)
}
Thanks guys, please help.
|
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04292 seconds