Showing posts with label databases. Show all posts
Showing posts with label databases. Show all posts

Thursday, March 29, 2012

Comparing two SQLServer databases

Hi, does anybody know a nice tool to automatically compare and show
only the structural differences between two databases, this is, the
differences in the columns of a table, constrains, data type, etc.

Thanks

J.A.I use this one (there are a number of other, simipar products):

http://www.red-gate.com/SQL_Compare.htm

Simon|||For excellent compare functionality (including data) plus the ability
to link your source control system into the whole process I recommend
looking at DB Ghost (www.dbghost.com). It also guarantees any delta
script produced will work (due to a unique algorithm), something no
other tool can promise.

Comparing two different databases

Hi all,
Sql server 7

i have two databases best and books.Most of the tables present in best are in books except some.
i have been given a task to list out the tables and columns of which are present in best database and not in books database.

Pls suggest me the simplest and quickest way to do this.
this is very urgent.

waiting for reply.
TIA
AdilI'd just run selects from sysobjects and syscolumns, which are SQL Server's method of storing object definitions. Others on this forum will probably suggest selecting from the SCHEMA tables.|||Check LEFT OUTER JOIN in BOL, this should be very trivial (hint: ...no, t's too trivial ;) )|||hi

thnks for reply

can u tell me as to how i can select columns of a particular table using syscolumns

thansks once again|||Originally posted by aadil
hi

thnks for reply

can u tell me as to how i can select columns of a particular table using syscolumns

thansks once again

You could use linked servers. Query below will return list of tables from server1 if these are no the same column(s) on server2. Checking for object owner also is included.

select 'User table ['+su.name+'.'+so.name+'] does not have column ['+sc.name+']'
from server1.dbo.sysobjects so
join server1.dbo.syscolumns sc on sc.id=so.id
join server1.dbo.sysusers su on su.uid=so.uid
where so.xtype='U'
and exists(select 'ok' from server2.dbo.sysobjects r
join server2.dbo.sysusers sur on sur.uid=r.uid and sur.name=su.name
where xtype='U' and r.name=so.name)
and not exists(select 'ok' from server2.dbo.sysobjects sor
join server2.dbo.sysusers sul on sul.uid=sor.uid and sul.name=su.name
join server2.dbo.syscolumns scr on scr.id=sor.id
where sor.xtype='U' and sor.name=so.name and scr.name=sc.name)'

Comparing two databases for deleted records

hi ,
there is a tool that do compare between 2 databases and display deleted records an changes in schema and data ,
it's friendlly tool with beautiful gui for users.
it is called dbMaestro.
You can find it here:
http://www.extreme.co.il
You might want to check out the Red-Gate tools SQL Compare and SQL
DataCompare. I think these tools will do what you are requesting. Here is
their website: http://www.red-gate.com/
----
Need SQL Server Examples check out my website at
http://www.geocities.com/sqlserverexamples
"yaniv cohen" <yanivc@.extreme.co.il> wrote in message
news:30D974F8-F7EC-4AD7-BCC7-DDE5D9146096@.microsoft.com...
> hi ,
> there is a tool that do compare between 2 databases and display deleted
records an changes in schema and data ,
> it's friendlly tool with beautiful gui for users.
> it is called dbMaestro.
> You can find it here:
> http://www.extreme.co.il
>

Comparing two databases for deleted records

How do I compare two databases to determine deleted
records."Aboki" <anonymous@.discussions.microsoft.com> wrote in message
news:13d7001c41b24$a4d4d240$a001280a@.phx
.gbl...
> How do I compare two databases to determine deleted
> records.
Select *
from dbArchive.dbo.table1 as a
left outer join
dbUpdated.dbo.table1 as u
on a.PK = u.PK
where u.pk is null
dbArchive = the old database name
dbUpdated = the one with the rows deleted
PK = whatever the Primary Key column is
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.647 / Virus Database: 414 - Release Date: 29/03/2004|||hi ,
there is a tool that do compare between 2 databases and display deleted reco
rds an changes in schema and data ,
it's friendlly tool with beautiful gui for users.
it is called dbMaestro.
You can find it here:
http://www.extreme.co.il|||You might want to check out the Red-Gate tools SQL Compare and SQL
DataCompare. I think these tools will do what you are requesting. Here is
their website: http://www.red-gate.com/
----
----
--
Need SQL Server Examples check out my website at
http://www.geocities.com/sqlserverexamples
"yaniv cohen" <yanivc@.extreme.co.il> wrote in message
news:30D974F8-F7EC-4AD7-BCC7-DDE5D9146096@.microsoft.com...
> hi ,
> there is a tool that do compare between 2 databases and display deleted
records an changes in schema and data ,
> it's friendlly tool with beautiful gui for users.
> it is called dbMaestro.
> You can find it here:
> http://www.extreme.co.il
>

Comparing two databases

Are there any tools that allow you to compare two sql server databases to
find out what is different between them (the database structure, including
tables, relationships etc)? Thanks,
- Gabe
http://www.red-gate.com/sql/summary.htm
AMB
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>
|||Gabe Matteson wrote:
> Are there any tools that allow you to compare two sql server
> databases to find out what is different between them (the database
> structure, including tables, relationships etc)? Thanks,
> - Gabe
There are numerous schema comparison tools available. Change Manager
from Imceda/Quest Software available at www.imceda.com.
David Gugick
Quest Software
www.imceda.com
www.quest.com
|||Seconding this one...I've been using Red-gate SQL and Data compare for 2
years...fantastic products...
Kevin Hill
President
3NF Consulting
www.3nf-inc.com/NewsGroups.htm
www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
www.experts-exchange.com - experts compete for points to answer your
questions
"Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...[vbcol=seagreen]
> http://www.red-gate.com/sql/summary.htm
>
> AMB
> "Gabe Matteson" wrote:
|||Thanks!
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
|||ErWin and ER-Studio do this as well.
Greg Jackson
PDX, Oregon
|||I agree. SQL Compare from Red Gate is brilliant.
"Kevin3NF" wrote:

> Seconding this one...I've been using Red-gate SQL and Data compare for 2
> years...fantastic products...
> --
> Kevin Hill
> President
> 3NF Consulting
> www.3nf-inc.com/NewsGroups.htm
> www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
> www.experts-exchange.com - experts compete for points to answer your
> questions
>
> "Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
> news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...
>
>
|||you may want to look at a complete approach to change management, from your
favourite source control to your target database - DB Ghost
http://www.dbghost.com & the scripts produced always work - it's all in the
way they're produced.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>
|||I use red-gate
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
|||when red-gate fails (script out put has errors), DB Ghost succeeds which is
why most of our customers used to be red-gate customers.
free for MVP's, educational and non-profit organizations.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Wayne Snyder" wrote:

> I use red-gate
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
> news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
>
>

Comparing two databases

Is there a way to compare the strored procedure,views and UDF's between two
databases to see if there are any differences. I use one database for
developement and the other is online. I would like to be able to run a
structural comparison between the two to make sure i didn't forget to script
a function or stored procedure after making modifications. I normally just
script all objects from developement to online after mods but I would like t
o
know for certain they are both the same sometimes. Also I would like to read
up on best practices for tracking developement so if you know of any good
reading that would help me. I use MS Access project as a front end and SQL
2000 as the Be. Thanks> Is there a way to compare the strored procedure,views and UDF's between
> two
> databases to see if there are any differences. I use one database for
> developement and the other is online. I would like to be able to run a
> structural comparison between the two to make sure i didn't forget to
> script
> a function or stored procedure after making modifications.
SQL Compare 4.0
http://www.red-gate.com/|||"AkAlan" <AkAlan@.discussions.microsoft.com> wrote in message
news:3A5AF648-8D41-441A-BA91-0EF14B5C09A0@.microsoft.com...
> Is there a way to compare the strored procedure,views and UDF's between tw
o
> databases to see if there are any differences. I use one database for
We use SQL Delta. Does wonders for our spare time! (maintaining/updating app
rox. 25 DB
installations)
http://www.sqldelta.com|||You should be checking your development and production scripts into some
type of source version control system. For example, Visual Source Safe has
an option to compare two projects and list files that are different, and it
has a feature for comparing two versions of a script side by side with
differences highlighted.
Also, you can script the databases to seperate folders and use a tool like
WinMerge to perform the comparisons:
http://groups.google.com/group/micr...br />
46abfa76
Rather than scripting all objects from development to production in bulk,
you need to identify specific objects that have changed and deploy them
individually. There are a number of reasons, but for one, you run the risk
of accidentally running a script that drops / recreates a table thus
resulting in data loss.
"AkAlan" <AkAlan@.discussions.microsoft.com> wrote in message
news:3A5AF648-8D41-441A-BA91-0EF14B5C09A0@.microsoft.com...
> Is there a way to compare the strored procedure,views and UDF's between
> two
> databases to see if there are any differences. I use one database for
> developement and the other is online. I would like to be able to run a
> structural comparison between the two to make sure i didn't forget to
> script
> a function or stored procedure after making modifications. I normally just
> script all objects from developement to online after mods but I would like
> to
> know for certain they are both the same sometimes. Also I would like to
> read
> up on best practices for tracking developement so if you know of any good
> reading that would help me. I use MS Access project as a front end and SQL
> 2000 as the Be. Thanks

Comparing two databases

Are there any tools that allow you to compare two sql server databases to
find out what is different between them (the database structure, including
tables, relationships etc)? Thanks,
- Gabehttp://www.red-gate.com/sql/summary.htm
AMB
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>|||Gabe Matteson wrote:
> Are there any tools that allow you to compare two sql server
> databases to find out what is different between them (the database
> structure, including tables, relationships etc)? Thanks,
> - Gabe
There are numerous schema comparison tools available. Change Manager
from Imceda/Quest Software available at www.imceda.com.
David Gugick
Quest Software
www.imceda.com
www.quest.com|||Seconding this one...I've been using Red-gate SQL and Data compare for 2
years...fantastic products...
Kevin Hill
President
3NF Consulting
www.3nf-inc.com/NewsGroups.htm
www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
www.experts-exchange.com - experts compete for points to answer your
questions
"Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...[vbcol=seagreen]
> http://www.red-gate.com/sql/summary.htm
>
> AMB
> "Gabe Matteson" wrote:
>|||Thanks!
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>|||ErWin and ER-Studio do this as well.
Greg Jackson
PDX, Oregon|||I agree. SQL Compare from Red Gate is brilliant.
"Kevin3NF" wrote:

> Seconding this one...I've been using Red-gate SQL and Data compare for 2
> years...fantastic products...
> --
> Kevin Hill
> President
> 3NF Consulting
> www.3nf-inc.com/NewsGroups.htm
> www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
> www.experts-exchange.com - experts compete for points to answer your
> questions
>
> "Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in messag
e
> news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...
>
>|||you may want to look at a complete approach to change management, from your
favourite source control to your target database - DB Ghost
http://www.dbghost.com & the scripts produced always work - it's all in the
way they're produced.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>|||I use red-gate
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>|||when red-gate fails (script out put has errors), DB Ghost succeeds which is
why most of our customers used to be red-gate customers.
free for MVP's, educational and non-profit organizations.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Wayne Snyder" wrote:

> I use red-gate
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
> news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
>
>sqlsql

Comparing two databases

Are there any tools that allow you to compare two sql server databases to
find out what is different between them (the database structure, including
tables, relationships etc)? Thanks,
- Gabe
http://www.red-gate.com/sql/summary.htm
AMB
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>
|||Gabe Matteson wrote:
> Are there any tools that allow you to compare two sql server
> databases to find out what is different between them (the database
> structure, including tables, relationships etc)? Thanks,
> - Gabe
There are numerous schema comparison tools available. Change Manager
from Imceda/Quest Software available at www.imceda.com.
David Gugick
Quest Software
www.imceda.com
www.quest.com
|||Seconding this one...I've been using Red-gate SQL and Data compare for 2
years...fantastic products...
Kevin Hill
President
3NF Consulting
www.3nf-inc.com/NewsGroups.htm
www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
www.experts-exchange.com - experts compete for points to answer your
questions
"Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...[vbcol=seagreen]
> http://www.red-gate.com/sql/summary.htm
>
> AMB
> "Gabe Matteson" wrote:
|||Thanks!
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
|||ErWin and ER-Studio do this as well.
Greg Jackson
PDX, Oregon
|||I agree. SQL Compare from Red Gate is brilliant.
"Kevin3NF" wrote:

> Seconding this one...I've been using Red-gate SQL and Data compare for 2
> years...fantastic products...
> --
> Kevin Hill
> President
> 3NF Consulting
> www.3nf-inc.com/NewsGroups.htm
> www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
> www.experts-exchange.com - experts compete for points to answer your
> questions
>
> "Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
> news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...
>
>
|||you may want to look at a complete approach to change management, from your
favourite source control to your target database - DB Ghost
http://www.dbghost.com & the scripts produced always work - it's all in the
way they're produced.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Gabe Matteson" wrote:

> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>
|||I use red-gate
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
|||when red-gate fails (script out put has errors), DB Ghost succeeds which is
why most of our customers used to be red-gate customers.
free for MVP's, educational and non-profit organizations.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Wayne Snyder" wrote:

> I use red-gate
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
> news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
>
>

Comparing two databases

Hi,
I would like to compare two sql server databases.
I need to find the difference in the two database(i.e table, colums,
data type)
Is there any free utility available to compare sql server database
I'm using sql server 2000.
Help me out to compare databases

Thanks & Regards,
ManiIt's not free, but you can download a 14-day trial version;
http://www.redgate.com/products/SQL_Compare/index.htm
Markus|||Another one is AlfaAlfa's SQL Server Comparison Tool (SCT)

http://www.sql-server-tool.com
- also not free, but it has 30 days of free evaluation period, which
can be extended to 90 days. Comparisons can be fully automated
through the usage of command line parameters.

SCT works with SQL Server 2005, 2000 and 7.0 and between these
versions.

Dariusz Dziewialtowski.

Comparing two databases

Are there any tools that allow you to compare two sql server databases to
find out what is different between them (the database structure, including
tables, relationships etc)? Thanks,
- Gabehttp://www.red-gate.com/sql/summary.htm
AMB
"Gabe Matteson" wrote:
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>|||Gabe Matteson wrote:
> Are there any tools that allow you to compare two sql server
> databases to find out what is different between them (the database
> structure, including tables, relationships etc)? Thanks,
> - Gabe
There are numerous schema comparison tools available. Change Manager
from Imceda/Quest Software available at www.imceda.com.
--
David Gugick
Quest Software
www.imceda.com
www.quest.com|||Seconding this one...I've been using Red-gate SQL and Data compare for 2
years...fantastic products...
--
Kevin Hill
President
3NF Consulting
www.3nf-inc.com/NewsGroups.htm
www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
www.experts-exchange.com - experts compete for points to answer your
questions
"Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...
> http://www.red-gate.com/sql/summary.htm
>
> AMB
> "Gabe Matteson" wrote:
>> Are there any tools that allow you to compare two sql server databases to
>> find out what is different between them (the database structure,
>> including
>> tables, relationships etc)? Thanks,
>> - Gabe
>>|||Thanks!
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>|||ErWin and ER-Studio do this as well.
Greg Jackson
PDX, Oregon|||I agree. SQL Compare from Red Gate is brilliant.
"Kevin3NF" wrote:
> Seconding this one...I've been using Red-gate SQL and Data compare for 2
> years...fantastic products...
> --
> Kevin Hill
> President
> 3NF Consulting
> www.3nf-inc.com/NewsGroups.htm
> www.DallasDBAs.com/forum - new DB forum for Dallas/Ft. Worth area DBAs.
> www.experts-exchange.com - experts compete for points to answer your
> questions
>
> "Alejandro Mesa" <AlejandroMesa@.discussions.microsoft.com> wrote in message
> news:E8C28859-7C90-4FD6-A40B-3490F7172846@.microsoft.com...
> > http://www.red-gate.com/sql/summary.htm
> >
> >
> > AMB
> >
> > "Gabe Matteson" wrote:
> >
> >> Are there any tools that allow you to compare two sql server databases to
> >> find out what is different between them (the database structure,
> >> including
> >> tables, relationships etc)? Thanks,
> >> - Gabe
> >>
> >>
> >>
>
>|||you may want to look at a complete approach to change management, from your
favourite source control to your target database - DB Ghost
http://www.dbghost.com & the scripts produced always work - it's all in the
way they're produced.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Gabe Matteson" wrote:
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>
>|||I use red-gate
--
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>|||when red-gate fails (script out put has errors), DB Ghost succeeds which is
why most of our customers used to be red-gate customers.
free for MVP's, educational and non-profit organizations.
regards,
Mark Baekdal
http://www.dbghost.com
http://www.innovartis.co.uk
+44 (0)208 241 1762
Build, Comparison and Synchronization from Source Control = Database change
management for SQL Server
"Wayne Snyder" wrote:
> I use red-gate
> --
> Wayne Snyder, MCDBA, SQL Server MVP
> Mariner, Charlotte, NC
> www.mariner-usa.com
> (Please respond only to the newsgroups.)
> I support the Professional Association of SQL Server (PASS) and it's
> community of SQL Server professionals.
> www.sqlpass.org
> "Gabe Matteson" <gmatteson@.inquery.biz.nospam> wrote in message
> news:OdFamzndFHA.1456@.TK2MSFTNGP15.phx.gbl...
> > Are there any tools that allow you to compare two sql server databases to
> > find out what is different between them (the database structure, including
> > tables, relationships etc)? Thanks,
> > - Gabe
> >
>
>|||'www.red-gate.com' (http://www.red-gate.com) or 'www.dbghost.com
(http://www.dbghost.com) are two software use to compare the databas
--
gheman
----
ghemant's Profile: http://www.msusenet.com/member.php?userid=234
View this thread: http://www.msusenet.com/t-187055366|||I use http://www.adeptsql.com SQL Diff Tool because it was so much
faster than red-gate.
Tim S|||Ive seen people script DBs and use "Beyond Compare" as well.
Greg Jackson
PDX, Oregon|||I use SQL Effects Clarity from http://www.sqleffects.com mostly because
of the side by side twin views of the schemas that lets you drill down
to the most minute differences.
Gabe Matteson wrote:
> Are there any tools that allow you to compare two sql server databases to
> find out what is different between them (the database structure, including
> tables, relationships etc)? Thanks,
> - Gabe
>

Comparing the schemas of two databases

Hi,
In SQL Server 2005, is there anything built-in which will compare two
databases and show how their schemas differ? Something similar to the Red
Gate software?
Any assistance gratefully received.
MarkNot yet but soon there will be a tool like that with the Visual Studio Team
Edition for Databases:
http://msdn.microsoft.com/vstudio/teamsystem/products/dbpro/
Andrew J. Kelly SQL MVP
"Mark Rae" <mark@.markNOSPAMrae.com> wrote in message
news:%23Cly$A5vGHA.4576@.TK2MSFTNGP03.phx.gbl...
> Hi,
> In SQL Server 2005, is there anything built-in which will compare two
> databases and show how their schemas differ? Something similar to the Red
> Gate software?
> Any assistance gratefully received.
> Mark
>

Comparing the schemas of two databases

Hi,
In SQL Server 2005, is there anything built-in which will compare two
databases and show how their schemas differ? Something similar to the Red
Gate software?
Any assistance gratefully received.
MarkNot yet but soon there will be a tool like that with the Visual Studio Team
Edition for Databases:
http://msdn.microsoft.com/vstudio/t...products/dbpro/
Andrew J. Kelly SQL MVP
"Mark Rae" <mark@.markNOSPAMrae.com> wrote in message
news:%23Cly$A5vGHA.4576@.TK2MSFTNGP03.phx.gbl...
> Hi,
> In SQL Server 2005, is there anything built-in which will compare two
> databases and show how their schemas differ? Something similar to the Red
> Gate software?
> Any assistance gratefully received.
> Mark
>

Tuesday, March 27, 2012

Comparing Tables and Columns Between Two Databases

Hi,

I have a two databases that may be similar but are not identical.I would like to compare the table and column names of the two databases to find out where they differ.Are there any tools that would help me in this task?In Oracle I would compare the meta data of the two databases in a select clause.Can we do the same thing in MS SQL?

Thanks in advance,

Dave

http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=23054 should get you what you are looking.

comparing tables

My employer has asked me to compare two databases which are not connected (1 in Oracle 7, and 1 in oracle 8). but with more or less the same set of tables and records (let's say: custumors and addresses). Can anyone give me a hint how to compare those tables. I need to know which records in one table are missing in the other one? I need to know which records have the same unique identification but different other attributes, etc.First, you need to establish a database link from one database to the other, so that you can connect to one database and select data from the other, e.g.

DB1> SELECT * FROM scott.emp@.DB2;

Your DBA should be able to help with this.

Then you can compare records. To see which records in DB1 are missing in DB2, run this in DB1:

SELECT keycol1, keycol2, ... FROM table1
MINUS
SELECT keycol1, keycol2, ... FROM table1@.DB2;

To find records where keys match but other attributes differ:

SELECT t1.keycol1, t1.keycol2, ...
FROM table t1, table@.DB2 t2
WHERE t1.keycol1 = t2.keycol1
AND t1.keycol2 = t2.keycol2
...
AND ( t1.attribute1 != t2.attribute1
OR t1..attribute2 != t2.attribute2
OR ...
);

BEWARE OF NULLS!!!

If attribute1 can be NULL, then you must allow for that. The correct way is:

NOT ( ( t1.attribute1 IS NULL AND t2.attribute1 IS NULL)
OR t1.attribute1 = t2.attribute1
)

A simpler way is:

NVL(t1.attribute1,'?') = NVL(t2.attribute1,'?')

... but you must be sure to pick a suitable value (e.g. '?') that is (a) valid for the datatype of attribute1 and (b) not a value that you will actually find in attribute1.

Comparing table structures between databases

Unfortunatly no there isn't an easy way.
If you have connection to the internet log on to the site
http://www.adeptsql.com/download.htm and download AdeptSQL
Diff ver 1.6.
We have used that for all our server and works very well.
N.B. You can program it yourself in SQL but will take a
bit of time, and this will hi-light every difference.
Peter
"What makes him think a middle aged actor [Clint
Eastwood], who's played with a chimp, could have a future
in politics?"
Ronald Reagan

>--Original Message--
>What is the easiest way to compare the table structure of
two databases?
>I have inherited a project and have found a couple of
undocumented
>inconsistencies between the development and production
databases.
>Is there an in-built function or a utility that can help
with this?
>Thanks,
>Mike
>
>.
>
Thanks, Peter.
That looks like it will do all I need and more.
Regards,
Mike
"Peter The Spate" <anonymous@.discussions.microsoft.com> wrote in message
news:4bbe01c490da$17ef8560$a601280a@.phx.gbl...[vbcol=seagreen]
> Unfortunatly no there isn't an easy way.
> If you have connection to the internet log on to the site
> http://www.adeptsql.com/download.htm and download AdeptSQL
> Diff ver 1.6.
> We have used that for all our server and works very well.
> N.B. You can program it yourself in SQL but will take a
> bit of time, and this will hi-light every difference.
> Peter
> "What makes him think a middle aged actor [Clint
> Eastwood], who's played with a chimp, could have a future
> in politics?"
> Ronald Reagan
>
> two databases?
> undocumented
> databases.
> with this?

Comparing table structures between databases

What is the easiest way to compare the table structure of two databases?
I have inherited a project and have found a couple of undocumented
inconsistencies between the development and production databases.
Is there an in-built function or a utility that can help with this?
Thanks,
MikeUnfortunatly no there isn't an easy way.
If you have connection to the internet log on to the site
http://www.adeptsql.com/download.htm and download AdeptSQL
Diff ver 1.6.
We have used that for all our server and works very well.
N.B. You can program it yourself in SQL but will take a
bit of time, and this will hi-light every difference.
Peter
"What makes him think a middle aged actor [Clint
Eastwood], who's played with a chimp, could have a future
in politics?"
Ronald Reagan
>--Original Message--
>What is the easiest way to compare the table structure of
two databases?
>I have inherited a project and have found a couple of
undocumented
>inconsistencies between the development and production
databases.
>Is there an in-built function or a utility that can help
with this?
>Thanks,
>Mike
>
>.
>|||Thanks, Peter.
That looks like it will do all I need and more.
Regards,
Mike
"Peter The Spate" <anonymous@.discussions.microsoft.com> wrote in message
news:4bbe01c490da$17ef8560$a601280a@.phx.gbl...
> Unfortunatly no there isn't an easy way.
> If you have connection to the internet log on to the site
> http://www.adeptsql.com/download.htm and download AdeptSQL
> Diff ver 1.6.
> We have used that for all our server and works very well.
> N.B. You can program it yourself in SQL but will take a
> bit of time, and this will hi-light every difference.
> Peter
> "What makes him think a middle aged actor [Clint
> Eastwood], who's played with a chimp, could have a future
> in politics?"
> Ronald Reagan
>
> >--Original Message--
> >What is the easiest way to compare the table structure of
> two databases?
> >
> >I have inherited a project and have found a couple of
> undocumented
> >inconsistencies between the development and production
> databases.
> >
> >Is there an in-built function or a utility that can help
> with this?
> >
> >Thanks,
> >
> >Mike
> >
> >
> >.
> >

Comparing table structures between databases

What is the easiest way to compare the table structure of two databases?
I have inherited a project and have found a couple of undocumented
inconsistencies between the development and production databases.
Is there an in-built function or a utility that can help with this?
Thanks,
MikeThanks, Peter.
That looks like it will do all I need and more.
Regards,
Mike
"Peter The Spate" <anonymous@.discussions.microsoft.com> wrote in message
news:4bbe01c490da$17ef8560$a601280a@.phx.gbl...[vbcol=seagreen]
> Unfortunatly no there isn't an easy way.
> If you have connection to the internet log on to the site
> http://www.adeptsql.com/download.htm and download AdeptSQL
> Diff ver 1.6.
> We have used that for all our server and works very well.
> N.B. You can program it yourself in SQL but will take a
> bit of time, and this will hi-light every difference.
> Peter
> "What makes him think a middle aged actor [Clint
> Eastwood], who's played with a chimp, could have a future
> in politics?"
> Ronald Reagan
>
> two databases?
> undocumented
> databases.
> with this?

Comparing table structure

Is there any tool to compare table structures between two databases?
For example: When comparing Table_A and Table_B, which fields are
missing, which relations are missing, etc.
Thanks,
GasparHello,
SQLCompare from Redgate software is a good DB structure and Data compare
software.
http://www.red-gate.com/products/SQL_Compare/index.htm
Thanks
Hari
"Gaspar" <gaspar@.no-reply.com> wrote in message
news:egp9yfLYHHA.3984@.TK2MSFTNGP02.phx.gbl...
> Is there any tool to compare table structures between two databases?
> For example: When comparing Table_A and Table_B, which fields are missing,
> which relations are missing, etc.
> Thanks,
> Gaspar

Comparing stored procedures

Hi!
I've got 2 databases: working one and test one.
I've changed a lot of procedures in test database.
How can I compare all procedures in that databases and select only changed
ones?
Thanks !I recommend that you implement a change control system, where you know which has changed and apply
only those. To do an actual compare, you need to write code or go to 3:rd party product. I haven't
used below myself, but I see it mentioned a lot:
http://www.red-gate.com/SQL_Compare.htm
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Dmitry Karneyev" <karneyev@.msn.com> wrote in message news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> Hi!
> I've got 2 databases: working one and test one.
> I've changed a lot of procedures in test database.
> How can I compare all procedures in that databases and select only changed
> ones?
> Thanks !
>|||For quick & dirty compare, use free tool QALite from site.
--
-oj
RAC v2.2 & QALite!
http://www.rac4sql.net
"Dmitry Karneyev" <karneyev@.msn.com> wrote in message
news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> Hi!
> I've got 2 databases: working one and test one.
> I've changed a lot of procedures in test database.
> How can I compare all procedures in that databases and select only changed
> ones?
> Thanks !
>|||Hi, Dmitry
I always add some comment in my stored procedures like
--It has been changed by Uri Dimant on some date.
Write script which loop through all strored procedures and looking for some
comments.
"Dmitry Karneyev" <karneyev@.msn.com> wrote in message
news:#f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> Hi!
> I've got 2 databases: working one and test one.
> I've changed a lot of procedures in test database.
> How can I compare all procedures in that databases and select only changed
> ones?
> Thanks !
>|||Hi Uri!
Could you post such script?
"Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> Hi, Dmitry
> I always add some comment in my stored procedures like
> --It has been changed by Uri Dimant on some date.
> Write script which loop through all strored procedures and looking for
some
> comments.|||Hi
Simple
SELECT SPECIFIC_NAME
FROM INFORMATION_SCHEMA.routines
WHERE ROUTINE_DEFINITION LIKE '%It has been changed%'
"Dmitry Karneyev" <karneyev@.msn.com> wrote in message
news:eXTqz9rnDHA.2776@.tk2msftngp13.phx.gbl...
> Hi Uri!
> Could you post such script?
> "Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
> news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> > Hi, Dmitry
> > I always add some comment in my stored procedures like
> > --It has been changed by Uri Dimant on some date.
> > Write script which loop through all strored procedures and looking for
> some
> > comments.
>|||You must to use the MS Visual Source Safe in a future to make a
version-control on of your procedures.
Hope this help,
"Dmitry Karneyev" <karneyev@.msn.com> escreveu na mensagem
news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> Hi!
> I've got 2 databases: working one and test one.
> I've changed a lot of procedures in test database.
> How can I compare all procedures in that databases and select only changed
> ones?
> Thanks !
>|||That may not be robust! What if you forgot to put in a comment in one of the
stored procedures?
--
Linchi Shea
linchi_shea@.NOSPAMml.com
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:uxw0lCsnDHA.3304@.tk2msftngp13.phx.gbl...
> Hi
> Simple
> SELECT SPECIFIC_NAME
> FROM INFORMATION_SCHEMA.routines
> WHERE ROUTINE_DEFINITION LIKE '%It has been changed%'
>
> "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> news:eXTqz9rnDHA.2776@.tk2msftngp13.phx.gbl...
> > Hi Uri!
> >
> > Could you post such script?
> >
> > "Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
> > news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > Hi, Dmitry
> > > I always add some comment in my stored procedures like
> > > --It has been changed by Uri Dimant on some date.
> > > Write script which loop through all strored procedures and looking
for
> > some
> > > comments.
> >
> >
>|||Linchi
Heee, good point.
That will be DBA's privilege and only one person should to do such things
like me in our company.
"Linchi Shea" <linchi_shea@.NOSPAMml.com> wrote in message
news:#S6zLGunDHA.744@.tk2msftngp13.phx.gbl...
> That may not be robust! What if you forgot to put in a comment in one of
the
> stored procedures?
> --
> Linchi Shea
> linchi_shea@.NOSPAMml.com
>
> "Uri Dimant" <urid@.iscar.co.il> wrote in message
> news:uxw0lCsnDHA.3304@.tk2msftngp13.phx.gbl...
> > Hi
> > Simple
> > SELECT SPECIFIC_NAME
> > FROM INFORMATION_SCHEMA.routines
> > WHERE ROUTINE_DEFINITION LIKE '%It has been changed%'
> >
> >
> > "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> > news:eXTqz9rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > Hi Uri!
> > >
> > > Could you post such script?
> > >
> > > "Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
> > > news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > > Hi, Dmitry
> > > > I always add some comment in my stored procedures like
> > > > --It has been changed by Uri Dimant on some date.
> > > > Write script which loop through all strored procedures and looking
> for
> > > some
> > > > comments.
> > >
> > >
> >
> >
>|||Thanks Linchi!
"Linchi Shea" <linchi_shea@.NOSPAMml.com> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ
ÓÌÅÄÕÀÝÅÅ: news:O2DNNRunDHA.2000@.TK2MSFTNGP12.phx.gbl...
> Here's a Perl script for comparing two stored procedures. You can use it
> compare any number of stored procedures. The first time it runs, it takes
> time to load SQL-DMO. An HTML doc is included in the zip file.
> --
> Linchi Shea
> linchi_shea@.NOSPAMml.com
>
> "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> > Hi!
> >
> > I've got 2 databases: working one and test one.
> > I've changed a lot of procedures in test database.
> >
> > How can I compare all procedures in that databases and select only
changed
> > ones?
> >
> > Thanks !
> >
> >
>
>|||Hi Linchi,
How to get the perl script you mentioned? I am having the
same problem and want to use your script to give a try.
Thanks in advance,
New Bee
>--Original Message--
>Here's a Perl script for comparing two stored procedures.
You can use it
>compare any number of stored procedures. The first time
it runs, it takes
>time to load SQL-DMO. An HTML doc is included in the zip
file.
>--
>Linchi Shea
>linchi_shea@.NOSPAMml.com
>
>"Dmitry Karneyev" <karneyev@.msn.com> wrote in message
>news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
>> Hi!
>> I've got 2 databases: working one and test one.
>> I've changed a lot of procedures in test database.
>> How can I compare all procedures in that databases and
select only changed
>> ones?
>> Thanks !
>>
>
>|||Please check DB Ghost at www.dbghost.com
Thanks,
Darren Fuller MCSE
>--Original Message--
>Hi!
>I've got 2 databases: working one and test one.
>I've changed a lot of procedures in test database.
>How can I compare all procedures in that databases and
select only changed
>ones?
>Thanks !
>
>.
>|||also routine_definition is not a reliable way to check for code.
e.g.
declare @.s1 varchar(8000),@.s2 varchar(8000),@.s3 varchar(8000)
select @.s1='create proc _usp as select ''',
@.s2=replicate('1',8000),
@.s3=replicate('2',8000)
exec(@.s1+@.s2+@.s3+'abc'' as mycol')
go
SELECT *
FROM INFORMATION_SCHEMA.routines
WHERE ROUTINE_DEFINITION LIKE '%abc'
select text
from syscomments
where id=object_id('_usp')
go
drop proc _usp
go
-oj
RAC v2.2 & QALite!
http://www.rac4sql.net
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:uxw0lCsnDHA.3304@.tk2msftngp13.phx.gbl...
> Hi
> Simple
> SELECT SPECIFIC_NAME
> FROM INFORMATION_SCHEMA.routines
> WHERE ROUTINE_DEFINITION LIKE '%It has been changed%'
>
> "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> news:eXTqz9rnDHA.2776@.tk2msftngp13.phx.gbl...
> > Hi Uri!
> >
> > Could you post such script?
> >
> > "Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
> > news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > Hi, Dmitry
> > > I always add some comment in my stored procedures like
> > > --It has been changed by Uri Dimant on some date.
> > > Write script which loop through all strored procedures and looking
for
> > some
> > > comments.
> >
> >
>|||NB;
I attached to my previous post. Are you not able to get the attached file? I can email you offline.
Also, the script requires the Perl module Parse::RecDescent which you can get from www.cpan.org. I use this module to parse T-SQL code to stripe off whitespaces and comments in case you don't want to compare them. You can choose to include them in the comparison if you want.
Linchi
>--Original Message--
>Thanks Linchi!
>"Linchi Shea" <linchi_shea@.NOSPAMml.com> ==D3=CF=CF=C2=DD=C9=CC/=D3=CF=CF=C2=DD=C9=CC=C1 =D7 =CE=CF=D7=CF=D3=D4=D1=C8
>=D3=CC=C5=C4=D5=C0=DD=C5=C5: =news:O2DNNRunDHA.2000@.TK2MSFTNGP12.phx.gbl...
>> Here's a Perl script for comparing two stored procedures. You can use it
>> compare any number of stored procedures. The first time it runs, it takes
>> time to load SQL-DMO. An HTML doc is included in the zip file.
>> -- >> Linchi Shea
>> linchi_shea@.NOSPAMml.com
>>
>> "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
>> news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
>> > Hi!
>> >
>> > I've got 2 databases: working one and test one.
>> > I've changed a lot of procedures in test database.
>> >
>> > How can I compare all procedures in that databases and select only
>changed
>> > ones?
>> >
>> > Thanks !
>> >
>> >
>>
>
>.
>|||Even in a single DBA shop, it can end up biting you for DBAs can be
forgetful :-) In a multi-DBA shop, it's not going to work at all.
--
Linchi Shea
linchi_shea@.NOSPAMml.com
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:OQHYBLunDHA.688@.TK2MSFTNGP10.phx.gbl...
> Linchi
> Heee, good point.
> That will be DBA's privilege and only one person should to do such
things
> like me in our company.
>
> "Linchi Shea" <linchi_shea@.NOSPAMml.com> wrote in message
> news:#S6zLGunDHA.744@.tk2msftngp13.phx.gbl...
> > That may not be robust! What if you forgot to put in a comment in one of
> the
> > stored procedures?
> >
> > --
> > Linchi Shea
> > linchi_shea@.NOSPAMml.com
> >
> >
> > "Uri Dimant" <urid@.iscar.co.il> wrote in message
> > news:uxw0lCsnDHA.3304@.tk2msftngp13.phx.gbl...
> > > Hi
> > > Simple
> > > SELECT SPECIFIC_NAME
> > > FROM INFORMATION_SCHEMA.routines
> > > WHERE ROUTINE_DEFINITION LIKE '%It has been changed%'
> > >
> > >
> > > "Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> > > news:eXTqz9rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > > Hi Uri!
> > > >
> > > > Could you post such script?
> > > >
> > > > "Uri Dimant" <urid@.iscar.co.il> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ
ÓÌÅÄÕÀÝÅÅ:
> > > > news:e02Zt6rnDHA.2776@.tk2msftngp13.phx.gbl...
> > > > > Hi, Dmitry
> > > > > I always add some comment in my stored procedures like
> > > > > --It has been changed by Uri Dimant on some date.
> > > > > Write script which loop through all strored procedures and
looking
> > for
> > > > some
> > > > > comments.
> > > >
> > > >
> > >
> > >
> >
> >
>|||NB;
Drop me an email!
--
Linchi Shea
linchi_shea@.NOSPAMml.com
"NB" <anonymous@.discussions.microsoft.com> wrote in message
news:0a6601c39eef$06556d20$a501280a@.phx.gbl...
> Hi Linchi,
> How to get the perl script you mentioned? I am having the
> same problem and want to use your script to give a try.
> Thanks in advance,
> New Bee
> >--Original Message--
> >Here's a Perl script for comparing two stored procedures.
> You can use it
> >compare any number of stored procedures. The first time
> it runs, it takes
> >time to load SQL-DMO. An HTML doc is included in the zip
> file.
> >
> >--
> >Linchi Shea
> >linchi_shea@.NOSPAMml.com
> >
> >
> >"Dmitry Karneyev" <karneyev@.msn.com> wrote in message
> >news:%23f9gVqrnDHA.708@.TK2MSFTNGP10.phx.gbl...
> >> Hi!
> >>
> >> I've got 2 databases: working one and test one.
> >> I've changed a lot of procedures in test database.
> >>
> >> How can I compare all procedures in that databases and
> select only changed
> >> ones?
> >>
> >> Thanks !
> >>
> >>
> >
> >
> >

Comparing SQL Databases

I've written an Access application that uses SQL Server 2005 for the backend.
I currently have about 10 clients using the application. When I have an
update for my clients I send them a script containing all the updates for the
server. The script contains ALTER, CREATE, etc procedures.
Unfortunately, one package had some problems and subsequently did not append
or process the entire script. The problem is, I don't know what has failed,
and therefore I don't know what procedures, views or tables may be incorrect.
My server is 100% accurate.
Is there a utility on the market that would compare two servers and report
what is missing or not the same in a report. Or better yet, one that creates
a script to bring them in snyc with each other. This would help me solve this
problem plus I would then not have to keep track of every change I make to
the server as I'm working.
Or, does SQL Server have a utility that does this?
Thanks.
www.red-gate.com
www.apexsql.com
Andrew J. Kelly SQL MVP
"Greg" <AccessVBAnet@.newsgroups.nospam> wrote in message
news:E2C743BE-339D-477A-BF56-3C520F3FB611@.microsoft.com...
> I've written an Access application that uses SQL Server 2005 for the
> backend.
> I currently have about 10 clients using the application. When I have an
> update for my clients I send them a script containing all the updates for
> the
> server. The script contains ALTER, CREATE, etc procedures.
> Unfortunately, one package had some problems and subsequently did not
> append
> or process the entire script. The problem is, I don't know what has
> failed,
> and therefore I don't know what procedures, views or tables may be
> incorrect.
> My server is 100% accurate.
> Is there a utility on the market that would compare two servers and report
> what is missing or not the same in a report. Or better yet, one that
> creates
> a script to bring them in snyc with each other. This would help me solve
> this
> problem plus I would then not have to keep track of every change I make to
> the server as I'm working.
> Or, does SQL Server have a utility that does this?
> Thanks.
|||Hi,
I understand that one of your packages failed to execute and you would like
to know if there is a tool to compare two servers and report what is
missing or not the same in a report.
If I have misunderstood, please let me know.
I do not know if there is a third party tool for your concern, however I
think that you can try using SQL Profiler to monitor your SQL Server 2005
and look at the trace logs for manually checking the differences.
You may refer to:
Introducing SQL Server Profiler
http://msdn2.microsoft.com/en-us/library/ms181091.aspx
Using SQL Server Profiler
http://msdn2.microsoft.com/en-us/library/ms187929.aspx
Please feel free to let me know if you have any other questions or
concerns. Have a nice day!
Best regards,
Charles Wang
Microsoft Online Community Support
================================================== ====
When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
================================================== ====
This posting is provided "AS IS" with no warranties, and confers no rights.
================================================== ====
|||Also look at xsql.
http://www.xsqlsoftware.com/Main.aspx
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Greg" <AccessVBAnet@.newsgroups.nospam> wrote in message
news:E2C743BE-339D-477A-BF56-3C520F3FB611@.microsoft.com...
> I've written an Access application that uses SQL Server 2005 for the
> backend.
> I currently have about 10 clients using the application. When I have an
> update for my clients I send them a script containing all the updates for
> the
> server. The script contains ALTER, CREATE, etc procedures.
> Unfortunately, one package had some problems and subsequently did not
> append
> or process the entire script. The problem is, I don't know what has
> failed,
> and therefore I don't know what procedures, views or tables may be
> incorrect.
> My server is 100% accurate.
> Is there a utility on the market that would compare two servers and report
> what is missing or not the same in a report. Or better yet, one that
> creates
> a script to bring them in snyc with each other. This would help me solve
> this
> problem plus I would then not have to keep track of every change I make to
> the server as I'm working.
> Or, does SQL Server have a utility that does this?
> Thanks.
|||On Jul 27, 7:56 pm, Greg <AccessVBA...@.newsgroups.nospam> wrote:
> I've written an Access application that usesSQLServer2005 for the backend.
> I currently have about 10 clients using the application. When I have an
> update for my clients I send them a script containing all the updates for theserver. The script contains ALTER, CREATE, etc procedures.
> Unfortunately, one package had some problems and subsequently did not append
> or process the entire script. The problem is, I don't know what has failed,
> and therefore I don't know what procedures, views or tables may be incorrect.
> Myserveris 100% accurate.
> Is there a utility on the market that wouldcomparetwo servers and report
> what is missing or not the same in a report. Or better yet, one that creates
> a script to bring them in snyc with each other. This would help me solve this
> problem plus I would then not have to keep track of every change I make to
> theserveras I'm working.
> Or, doesSQLServerhave a utility that does this?
> Thanks.
Hi Greg,
check out xSQL Software's products, xSQL Object and xSQL Data Compare.
Those two utilities are completely free for SQL Server Express and
there is also a free lite edition that supports any SQL Server
Edition. You can download the products from http://www.xsqlsoftware.com
Thanks,
JC
xSQL Software
http://www.xsqlsoftware.com
|||xSQL Compare comes in a Lite edition that works without restrictions if you
are using SQL Server Express. I downloaded the full professional product and
tested it against my two databases and it reported all the differences
between the two of them. And, on top of that it automatially generated teh
scripts to update the differences as well.
This is an excellent product and meets my needs 100%.
"Hilary Cotter" wrote:

> Also look at xsql.
> http://www.xsqlsoftware.com/Main.aspx
> --
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "Greg" <AccessVBAnet@.newsgroups.nospam> wrote in message
> news:E2C743BE-339D-477A-BF56-3C520F3FB611@.microsoft.com...
>
>
|||www.dbconstructor.com
Robert Allen Schambach
"Greg" <AccessVBAnet@.newsgroups.nospam> wrote in message
news:E2C743BE-339D-477A-BF56-3C520F3FB611@.microsoft.com...
> I've written an Access application that uses SQL Server 2005 for the
> backend.
> I currently have about 10 clients using the application. When I have an
> update for my clients I send them a script containing all the updates for
> the
> server. The script contains ALTER, CREATE, etc procedures.
> Unfortunately, one package had some problems and subsequently did not
> append
> or process the entire script. The problem is, I don't know what has
> failed,
> and therefore I don't know what procedures, views or tables may be
> incorrect.
> My server is 100% accurate.
> Is there a utility on the market that would compare two servers and report
> what is missing or not the same in a report. Or better yet, one that
> creates
> a script to bring them in snyc with each other. This would help me solve
> this
> problem plus I would then not have to keep track of every change I make to
> the server as I'm working.
> Or, does SQL Server have a utility that does this?
> Thanks.