Hi there, I'm experimenting with a SL 2.0 Beta 1 App that's using a WCF webservice to make asynchronous calls to a SQL Server 2005 express database using LINQ. The App is running nicely on my home machine, however I'd like to know about the deployment. 1. The webservice (*.svc) needs to be uploaded to the root directory while it's code-behind files should have their paths the same as on my home machine ? /App_Code/IService.cs (interface) /AppCode/Service.cs (service) 2. The LINQ to SQL classes file (*.dbml) should be put in the same dir as on my home machine ? /App_Code/DataClasses.dbml 3. Can I just copy the *.mdf database file I've created at home ? or do I have to purchase a database here and populate it somehow (if so - why and how) ? 4. Please tell me about any connection strings I need to change/alter in order to make everything work. If you have trouble understanding my questions (my english is poor) please consider : what would have to be done in order to deploy the latest tutorial on SL 2.0 Beta 1 http://silverlight.net/learn/tutorials/sqldatagrid.aspx ? Sincirely
Hi, You will need to add a SQL Server 2005 account. From your SQL Express you can Attach the Express database to the SQL 2005 server once you have it or... You can create SQL in Express and run/import it with several methods. Salute, Mark
Ok, please assume that I'm english impaired / new to .NET etc. And tell me about any connection strings that I might need to change or alter. Also, where do I find information about attaching my own file?
In your Control Panel there's an option to Attach an Express DB if you have a SQL Server 2005 addon. Doesn't exist for the SQL 2000 addon. You should only use it with a blank DB as it will overwrite everything in the DB. It is however a very handy feature because getting data from SQL Express to regular SQL Servers is not easy. This is the way I do it when the Attach DB method is not used... Export the Express database as a script, with objects, from SQL Express. Export the Express DB records as *.csv files. Run the exported script in a SQL Server 2005 Management query window. The tables and objects are then created. Import the *.csv files which contain the records. As you can see the Attach method is much quicker and it does not require you to have a Developer copy of SQL Server locally. Any help you need please let me know. Salute, Mark