c# - Switch to local database -


I was suggested to have a question on time, so here it is.

Being a local copy of a website-project, I was thrown with a lot of documentation and now I have to develop some things for this. What I want to do is to use the local database and not to be on the server to ensure that I can check things properly. I have a website error and can be run but need to redirect the database. And I'm not sure how to change it.

  & lt; ConnectionStrings & gt; & Lt ;! Add name = "MySqlConnection" connectionString = "Data Source = 11.11.111.11; Database = Vebsaitnam; USER ID = websitename; PASSWORD = xxxxxx; port = 1234" / - & gt; & Lt; Add name = "MySqlConnection" connectionString = "Data Source = localhost; Database = Vebsaitnm; User ID = username; password = xxxxxxx; port = 1234" / & gt;  

I think I have "data source = 11.11.111.11;" Such as "data source = \ databasename.sql" or something like that.

In addition ... It appears that every time I try to connect the database in a way or does not want anyone else do this, instead of an .mdf file on the .sql file But the server-side does not care about it.

Thanks in advance.

The correct solution depends on the rdbms you are using (can you use a RDBM Are you? Do you have mysql / sqlserver / postgre installed?). If you have a rdbms on the production web server, you must install rdbms on your machine (or on the test server) and create a test database that a test database will fit on the production server but it is for you .

If you have a file (eg: access MDB) then copy that file locally and modify the connection string accordingly.

You can see that a detailed list of examples of different databases exists for the signal on the connection string.


Comments

Popular posts from this blog

Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -

multithreading - PhantomJS-Node in a for Loop -

c++ - MATLAB .m file to .mex file using Matlab Compiler -