How to Use VS2008 Command prompt to generate Datab

2019-09-13 01:34发布

问题:

created a sqlce Db with VS2008 and save a copy in C:\ Temp08.

can someone point out what was wrong with this Sqlmetal syntax :

sqlmetal c:\Users\DELL\Documents\Temp08\NtwContacts.sdf/ code:c:\Users\DELL\Documents\Temp08\NtwContactsData.cs/language:cs/namespace:LocalDB/context:NtwContactsDataContext /pluralize

Error : SQm1003: Input file ' code:c:\Users\DELL\Documents\Temp08\NtwContactsData.cs/language:cs/namespace:LocalDB/context:NtwContactsDataContext -- does not exist

My machine status : win7 pro Using VS2008 and VS2010 express for windows phone.

----- 20/Jul : have tested these conditions:

sqlmetal c:\Users\DELL\Documents\Temp08\NtwContacts.sdf/code:c:\Users\DELL\Documents\Temp08\NtwContactsData.cs/language:cs/namespace:LocalDB/context:NtwContactsDataContext/pluralize

Try these : no space in between

1) / code: ---> /code

2) language:cs --- > language:csharp or language:cs

3) C or c

--Result: Same problem

Questions :
1. When I test this : sqlmetal C:\Users\DELL\Documents\Temp08\NtwContacts.sdf

There is a return result on the command prompt with the table structure in Xml .

  1. What seem to be the problem?

回答1:

It should be: NtwContacts.sdf /code