0

I can't seem to generate a dbml file using Sqlmetal for a simple SSCE 3.5 db.

I am using the VS command prompt, am sitting in the VS project directory that contains the db, and then enter the following Sqlmetal command at the prompt :

sqlmetal /dbml:fom.dbml fom.sdf

sqlmetal returns the following error :

Error : Format of the initialization string does not conform to specification st arting at index 0.

Can anyone see what I am doing wrong here ?

[Note that I am running Windows 7 64. I have tried all three VS command prompts.. all result in same error].

Bazza Formez
  • 179
  • 5
  • 16
  • 1
    Do you have both the x86 and x64 SQL Server Compact runtime MSIs installed? – ErikEJ Jun 11 '12 at 06:24
  • I have now solved this particular error...SQLMetal did not seem to like directory names with spaces in them After moving db to a simple directory (eg. c:\temp) I was able to generate a dbml. However, now I have a new issue. The new dbml appears in visual studio 2010 ok, ie. model can be displayed. However, context classes are not generated - ie. there is no code behind the dbml at all it seems. – Bazza Formez Jun 11 '12 at 19:36
  • Also, yes, I have both SQL Server Compact 3.5 SP2 ENU & SQL Server Compact 3.5 SP2 x64 ENU installed. – Bazza Formez Jun 11 '12 at 19:41
  • OK, so your question did not reveal that your were using a path with spaces.. suggest you update the question. Why not simply generated the .cs files instead? – ErikEJ Jun 12 '12 at 07:31

1 Answers1

0

I have now solved this particular error...SQLMetal did not seem to like directory names with spaces in them After moving db to a simple directory without any spaces in directory name (eg. c:\temp\mydb.sdf) I was able to generate a dbml successfully.

Bazza Formez
  • 179
  • 5
  • 16