i set up a site in orchard cms.while choosing data storage settings i choose "used an existing SQL Server(or SQL Express) database" option instead of "used built-in data storage(SQL Server compact)".its worked fine for me but i am wondering where to change the data source that is the database server name.i didn't find the connection string settings in web.config file.
any help would be greatly appreciated. thanks.
To change the database, you should edit the DataConnectionString entry in the App_Data\Sites\Default\settings.txt file.
It should look something like this:
Name: Default
DataProvider: SqlServer
DataConnectionString: Data Source=servername;Initial Catalog=dbname;User Id=username;Password=password;
You do need to restart the website after the change is made. If you can't reset the webserver yourself, an edit in the web.config (add a space) or in the bin directory should suffice. .NET resets the website when something happens in this file or folder.
.\App_Data\Sites\Default\settings.txt
but you can't just change it to point to a empty database. the database needs to be prepared for orchard cms first.
Take a look at .\App_Data\Sites\Default\settings.txt.
To change connection string in Orchard you should go to Orchard.Web,in that App_Data\Sites\Default\Settings.Txt
来源:https://stackoverflow.com/questions/4781063/where-to-change-the-database-connection-settings-in-orchard-mvc-cms