3

this is my first project ^_^ and I have no previous experience. I did create the database in my project from within the MVC. Add New Item > SQL Server Database

then I use ADO.NET Entity DataModel

and I don't need to open my connection each time I deal with the database.. it's only the connection string in the Web.config..

my question is :

  1. how can I upload my database?
  2. is there any resource for such beginner as me :$ ?

I did Google it but I found it very hard for me to know if this is what I want or not, that's why I came here :$

Evanescence
  • 729
  • 1
  • 10
  • 25

2 Answers2

1

It really depends on what type of access you have to your server.

If you have remote desktop access then run remote desktop (mstsc in run) and connect to your server.

This article shows how to install your web application in IIS on server.

This blog post from Scott Guthrie shows you how to deploy your sql database to your server.

In case you only have access to your server via a control panel (plesk) you should still be able to do the same via a different interface. (you need to go through the instructions given for the specific control panel you are using).

Hope this helps.

Mo Valipour
  • 13,286
  • 12
  • 61
  • 87
  • hi valipour, thanks for ur answer, I access the server via a control panel, I'll try to follow the Scott Guthrie's post and hope it works with me :$ – Evanescence Jul 09 '11 at 02:22
  • (you'll have two .SQL installation scripts) I only got one, which is DB.MDF.sql and I did open it with M-SQL Server Management Studio and got all the tables then execute it.. then, I didn't know wt to do :S – Evanescence Jul 09 '11 at 09:32
0

For ASP.Net website, just upload all files using FTP, in wwwroot folder of your hosting.

For SQL Server database there are following option.

  1. Attach your MDF file on hosting database server (if you have remote desktop).

  2. Generate a script of whole database with full data, schema, and indexes etc. and run the script in query editor of your hosting panel.

  3. First of all create a database from your hosting panel and a user for your database then Use SQL Serer 2008 (R2 most preferable) and connect with your hosting SQL Server using hosting server name in Server name, your db user id in User Name, and same for password. And then connect, you will find a long list of databases including your own database. Now right click on your database and import data from your local database server to remote database server.

Xorsat
  • 2,388
  • 21
  • 21
  • 2- I did generate a script file from the wizard, when I restore the generated DB.MDF.sql it gives me an error message :$ – Evanescence Jul 09 '11 at 09:15
  • can you please write error message here, for further precaution check the top most line of script, USE database, here you must provide the database name of your hosting sql server. – Xorsat Jul 09 '11 at 22:05