Book a Demo

Author Topic: Generate DDL - 'table: Database not defined' error  (Read 8720 times)

andykennelly

  • EA User
  • **
  • Posts: 54
  • Karma: +0/-0
    • View Profile
Generate DDL - 'table: Database not defined' error
« on: February 19, 2014, 09:13:24 am »
I've used Model Transformation to create a platform specific model from a platform independent model and I know want to generate DDL to run in a SQL environment to create tables etc. To do this I'm right-clicking on the package with my platform specific model elements (diagram and tables) and selecting/generate DDL. I fill out the presented 'Generate Package DDL' box correctly (or so I believe), click Generate and see a 'table:Database not defined' message.
I can't find any guidance on Sparx Help nor the Forum. Trawling the web I see I might need to specify a default database in Tools\Options\Source Code Engineering\Code editors..... which I do (SQL 2008), but I still get the same message when attempting to generate DDL.

Any clues, Sparxites?

Dermot

  • EA Administrator
  • EA User
  • *****
  • Posts: 591
  • Karma: +7/-0
    • View Profile
Re: Generate DDL - 'table: Database not defined' e
« Reply #1 on: February 19, 2014, 02:59:24 pm »
I assume the transformed tables are now set to SQL Server?
Check that the Generate Package to DDL | Use Databse field is set to blank.
Best place to check things is in the EAxample model - run a default generation on this Database example.

Nizam Mohamed

  • EA User
  • **
  • Posts: 193
  • Karma: +1/-0
    • View Profile
Re: Generate DDL - 'table: Database not defined' e
« Reply #2 on: February 19, 2014, 03:04:50 pm »
Andy you may need to check if the default database is set, before transforming.
(Settings->Database Datatypes and set SQL Server as default).

Nizam