Showing posts with label startup. Show all posts
Showing posts with label startup. Show all posts

Thursday, March 29, 2012

Database startup time

Is it possible to find somewhere in the system table time of sql server startup?

Thanks

Hi, as the tempdb is created at very startup of the SQL Server service you can check the information on

sp_helpdb tempdb

HTH, Jens Suessmeyer,

http://www.sqlserver2005.de

sql

Database startup

in sql server (re)start where does it find the location of Master.mdf file .

In Oracle, there is control file where the location of *.dbf file is stored and Instance find the location of dbf file from that location

In sql server where it finds the location of Databases as master, msdb etc..

The location is set duing Server installation.

That information is stored in the registry. It can also be supplied as a command line start up parameter [ -dMasterFilePath ].

The registry location 'should' be:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\MSSQLServer\Parameters

Monday, March 19, 2012

Database schema comparison

Hello all. I am using Sql Compact Edition for a small standalone application, I create and build the initial database schema on initial startup. What I am looking for is a way to upgrade the software and on initial startup of the new version, I would like it to compare the existing database with a new schema and then update the database based on the difference. This way I can have a version that will update the database without me having to know what version it is to begin with. Is there a way to do this or am I asking too much?

Thank you,

Jim

This is something you will have to code yourself, however the key to doing this is to tap into the INFORMATION_SCHEMA views in SQL Compact Edition.

You can get metadata about all aspects of the schema of a SQL CE/SQL Mobile database using this view and then make determinations about old vs new schema as you compare two database versions. Books Online covers the INFORMATION_SCHEMA view and what it contains.

Regards,

Darren Shaffer