diff --git a/schemas/adl-0.dtd b/schemas/adl-0.dtd index 51224ef..0a0f30d 100755 --- a/schemas/adl-0.dtd +++ b/schemas/adl-0.dtd @@ -13,7 +13,7 @@ @@ -82,8 +82,15 @@ char(1) java.sql.Types.CHAR text: text or java.sql.Types.LONGVARCHAR memo java.sql.Types.CLOB + + Also, a hack, which may not belong here: + + serial: An integer whose value is automatically assigned by the database. Given + that Canonical ADL requires that every key must be specified, we + need a way of distinguishing those which are system generated from + those which aren't. This may not be the right way to do it! --> - + + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + exclude-result-prefixes="adl"> - + - - - Abstract key naming convention selected is '' - Locale selected is '' - *************************************************************************** @@ -52,7 +47,7 @@ * THIS FILE IS AUTOMATICALLY GENERATED AND SHOULD NOT * BE MANUALLY EDITED. * - * Generated using adl2canonical.xsl revision + * Generated using adl2canonical.xsl revision * *************************************************************************** @@ -61,20 +56,21 @@ - + entity already has a key - not generating one - + - + - '@natural-key' is deprecated - use the 'key' sub element instead - + + [In entity '']: '@natural-key' is deprecated - use the 'key' sub element instead + @@ -87,7 +83,7 @@ - + @@ -95,13 +91,13 @@ entity has no key - generating one - + - + @@ -133,23 +129,23 @@ - + - - + + - + - +
@@ -159,14 +155,14 @@ - +
- + @@ -176,14 +172,14 @@ - + - + @@ -193,13 +189,13 @@ - + - +
@@ -209,13 +205,13 @@ - +
- + @@ -225,14 +221,14 @@ - + - + @@ -242,7 +238,7 @@ - + - + - + + + + + ADL ERROR: Properties of type 'string' must have a valid value for 'size' + + + + + + ADL ERROR: Properties of type 'entity' must have a valid value for 'entity' + + + + + + ADL ERROR: Properties of type 'defined' must have a valid value for 'typedef' + + + diff --git a/transforms01/adl2entityclass.xslt b/transforms01/adl2entityclass.xslt index 2be496d..e0fd69a 100755 --- a/transforms01/adl2entityclass.xslt +++ b/transforms01/adl2entityclass.xslt @@ -1,6 +1,6 @@ + select="substring( '$Revision: 1.2 $', 11)"/> diff --git a/transforms01/adl2mssql.xslt b/transforms01/adl2mssql.xslt index 64c1fd2..85949dd 100755 --- a/transforms01/adl2mssql.xslt +++ b/transforms01/adl2mssql.xslt @@ -1,5 +1,8 @@ - + - + + - + ------------------------------------------------------------------------------------------------- -- -- Database for application version - -- Generated for MS-SQL 2000+ using adl2mssql.xsl $Revision: 1.1 $ + -- Generated for MS-SQL 2000+ using adl2mssql.xsl $Revision: 1.2 $ -- -- Code generator (c) 2007 Cygnet Solutions Ltd -- @@ -27,23 +31,23 @@ ------------------------------------------------------------------------------------------------- -- authentication roles ------------------------------------------------------------------------------------------------- - + ------------------------------------------------------------------------------------------------- -- tables, views and permissions ------------------------------------------------------------------------------------------------- - + ------------------------------------------------------------------------------------------------- -- referential integrity constraints ------------------------------------------------------------------------------------------------- - + - + @@ -55,7 +59,7 @@ - + @@ -87,7 +91,7 @@ ------------------------------------------------------------------------------------------------- - + execute sp_addrole @rolename = '' GO @@ -108,22 +112,35 @@ - + + ------------------------------------------------------------------------------------------------- -- primary table ------------------------------------------------------------------------------------------------- CREATE TABLE "" ( - - Id INT IDENTITY( 1, 1) PRIMARY KEY + + PRIMARY KEY, + + + , + ) GO ---- permissions ------------------------------------------------------------------------------ - + @@ -132,7 +149,7 @@ ---- link tables ------------------------------------------------------------------------------ - + @@ -342,21 +359,58 @@ - + -- Suppressing output of property , -- as it is the 'one' end of a one-to-many relationship - - "" INT DEFAULT NOT NULL, - + + INT IDENTITY( 1, 1) - - - + + + + + + + + + + + + + "" DEFAULT + + + + '' + + NOT NULL + + + + + + + + + + + "" DEFAULT NOT NULL + + + + + + + + + + + + + + + + + + + + + + + + + + ICollection<> + + + ICollection<> + + DATETIME + DATETIME + + VARCHAR( ) + TEXT + BIT + TIMESTAMP + INT + DOUBLE PRECISION + DECIMAL + INT IDENTITY( 1, 1) + [sql:unknown? []] + + diff --git a/transforms01/base-type-include.xslt b/transforms01/base-type-include.xslt new file mode 100755 index 0000000..e0bb6b7 --- /dev/null +++ b/transforms01/base-type-include.xslt @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + Looking for definition of ''; + Found to be defined as type '' + + + + integer + + + + + + + + + + + + + + + + + + + + + + +