Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Validating DB Schema Expand / Collapse
Author
Message
Posted Thursday, May 22, 2014 2:50 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, June 26, 2014 4:58 AM
Points: 7, Visits: 56
Hi , Im trying to validate if the db schema of about 3000 fields spread in about 15 tables matches the data dictionary(in excel) and also to keep a watch on it incase someone changes a column name or adds new column, i need to be alerted an hence would like to know if there is any easy way to validate it.Thanks for all the help
Post #1573798
Posted Thursday, May 22, 2014 3:29 PM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 3:14 PM
Points: 13,007, Visits: 12,425
Speedtest (5/22/2014)
Hi , Im trying to validate if the db schema of about 3000 fields spread in about 15 tables matches the data dictionary(in excel) and also to keep a watch on it incase someone changes a column name or adds new column, i need to be alerted an hence would like to know if there is any easy way to validate it.Thanks for all the help


Why do you have the data dictionary in Excel? You already have it defined exactly as sql server has it, right there in sql server. Trying to keep an external file up to date is going to be nearly impossible.

You might to take a look at DDL triggers. http://msdn.microsoft.com/en-us/library/ms175941.aspx


_______________________________________________________________

Need help? Help us help you.

Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

Need to split a string? Try Jeff Moden's splitter.

Cross Tabs and Pivots, Part 1 – Converting Rows to Columns
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs
Understanding and Using APPLY (Part 1)
Understanding and Using APPLY (Part 2)
Post #1573810
Posted Thursday, May 22, 2014 3:38 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, June 26, 2014 4:58 AM
Points: 7, Visits: 56
May be i wasnt clear in my question.....what i am trying to achieve is that when one developer makes changes to the tables, there got to be a way to check if its breaking another developers work...and hence i was thinking if we have some way to monitor the schema changes , then we can track and test such changes happening on db.....hope this helps
Post #1573813
Posted Thursday, May 22, 2014 5:54 PM
Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Monday, August 18, 2014 10:12 AM
Points: 63, Visits: 365
Are your table scripts under source control? Most (all?) source control systems can be set to email certain people when file changes are checked in.
Do you have a formal development process which involves impact analysis and code review? Do you have a daily build or continuous integration process with smoke tests?

Do you create your test database from scratch as part of your build? If so, you could run a schema check script against the previous build.
Do you have coding standards that say 'Don't use select *'? Do you limit the use of nullable columns and force default values for new columns added?

There are lots of ways to catch what you want.



Post #1573844
Posted Friday, May 23, 2014 2:18 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, June 26, 2014 4:58 AM
Points: 7, Visits: 56
Thank you so much for the reply. Apologies for still being unclear about the question raised by me , its a new job I started just few weeks back , and it looks like we are looking for automated unit tests to be carried out and its a continuos integfration with no smoke tests,Can you please guide me of what needs to be done to build some smoke tests for the datawarehouse in continuos integration ...are there any tools or any manual approach to do this.
Post #1573921
Posted Friday, May 23, 2014 5:19 AM
Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Monday, August 18, 2014 10:12 AM
Points: 63, Visits: 365
Ok, we are getting somewhere now. You have a data warehouse and it is running on data extracted from an OLTP database presumably.

Is your ETL process (extract,transform, load) process breaking because of schema changes in the OLTP database? Have you talked to the developers to make them aware that you need to know about schema changes? That's the easiest way to find out.

Do you have this on a development setup? Are the script changes stored in source control before being rolled out? What tools are you using? What's your development process?



Post #1573967
Posted Tuesday, May 27, 2014 1:42 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, June 26, 2014 4:58 AM
Points: 7, Visits: 56
Thank you so much for your help. Sorry for the late response ......Yes all I managed to find now it that we are looking to automate unit tests in the BI more like a regression pack and still its all vague and will try to dig deep into what exactly is needed and will get back shortly...But thank you so much for your time and help.
Post #1574678
Posted Thursday, August 7, 2014 5:07 PM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Wednesday, September 24, 2014 4:50 PM
Points: 358, Visits: 876
TFS has a schema compare feature, not sure if you use this source control program. I fished this out with a quick Internet search on applying the schema change function. http://msdn.microsoft.com/en-us/library/aa833435(v=vs.100).aspx. (TFS is integrated into Visual Studio).
Post #1600952
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse