Install database: Difference between revisions

From Heureka Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(15 intermediate revisions by one other user not shown)
Line 1: Line 1:
{{Languages}}
{{Languages|Install_database}}


A prerequisite to continue is that you have installed [[Install SQL Server | SQL Server]]
See http://heurekaslu.org/help/en/index.html?skapa_databas.htm


The input database must be installed, while the result database is created programatically by RegWise and PlanWise. StandWise does save results.


Instructions:
<!--
#Download an empty backup file (. Bak) of [ftp://salix.slu.se/Download/Heureka/Databases/ SLU FTP server] and save to your hard disk, for example, C:\TEMP\. If you are installing on a server, the file must be available locally on the server, and you must be logged on the server. You can also use another backup of a database that already contains data, if you have access to such.
==Create new or demo database==
# Use alternative 1 or 2 below
PlanStart version 1.0.3 and later lets you [[Create Forest Database | create a database]] automatically.


== Alternative 1: Use function in PlanStart to install database ==
==Install existing database==
This is the easiest method which does the same as in option 2 below, but in a simpler way. You use a function in PlanStart to create a database to which you can then import forest data, for example with [[The import of standalone registry | import a stock index]]. Do the following:
# Start PlanStart
# Select "Create Database Forest" from the "Tools" menu
# Click the "Browse"-button and select the directory where the backup file is located, eg C:\TEMP\.
# Select the backup file and click "Open". Note: Windows Vista may be sensitive to where the backup file is put, because SQL Server in Vista has restricted reading access. Anyhow, C:\temp\ should be OK.
# Enter the server name under the "Server":
# # If you have installed the free version, SQL Server 2005 Express, enter "localhost\SQLExpress"
# # If you have the commercial version of SQL Server, enter "localhost" if you install the database locally, or the server name if you are installing on a remote server.
# If you install locally, leave "Authentication" mode equal to "Windows authentication".
# In "Database name", type a database name (without blanks)
# Click the "Browse ..."-button next to "Location of data file", and specify a location where you want to save the database. See (4) above concerning problems with Vista.
# Click on "Create Database" and wait until ready.


If this does not work, then try the options below. See end of this page for common problems.
You can install an existing database either locally on <code>localhost</code> or on a central server (like <code>server1.mycompany.com</code>). It is assumed that you have [[Install SQL Server | installed]] or have access to SQL Server.


== Alternative 2: Run the "Restore" in SQL Server Management Studio ==
'''Prerequisite''': A backup file (. Bak) from an existing database.
Use the "Restore" function i SQL Server Management Studio to install the database:
# Open Management Studio. Enter the server name (localhost, localhost\SQLExpress, or the server name).
# Open Management Studio. Enter the server name (localhost, localhost\SQLExpress, or the server name).
# Right click on "Databases", select "New Database ..." and enter a name for the new database (no blanks or spaces)
# Right click on "Databases", select "New Database ..." and enter a name for the new database (no blanks or spaces)
Line 33: Line 21:
# In "Options", select "Overwrite ..." and change the "Restore as ..." to valid paths (folders must exist on your computer if you install locally, and on the server if you install on a remote server.
# In "Options", select "Overwrite ..." and change the "Restore as ..." to valid paths (folders must exist on your computer if you install locally, and on the server if you install on a remote server.


== Alternative. 3: Installing an .mdf file via the "Attach"-option in SQL Server Management Studio ==
'''Alternative:''' Install an .mdf file via the "Attach"-option in SQL Server Management Studio.
This alternative is available if you have an -mdf-file instead of a backup (.bak) file.
This alternative is available if you have an -mdf-file instead of a backup (.bak) file.
# Open Management Studio. Enter the server name (localhost, localhost\SQLExpress, or the server name).
# Open Management Studio. Enter the server name (localhost, localhost\SQLExpress, or the server name).
Line 40: Line 29:
# Click "Add" and select the .ndf file.
# Click "Add" and select the .ndf file.
# In the "Database details', check and if necessary edit the file path to valid ones.
# In the "Database details', check and if necessary edit the file path to valid ones.
[[Category:Reference Manual]]
[[Category:Software]]
[[Category:Install]]
[[Category:Database]]
-->

Latest revision as of 10:19, 26 November 2024