Showing posts with label dbs. Show all posts
Showing posts with label dbs. Show all posts

Sunday, March 25, 2012

Comparing DBs with Windiff

I scripted two versions of a database and then compared the text files using
WinDiff. There were major differences in the two files but Windiff said
they were the same "except for blanks." Has anyone else had such a problem
with WinDiff?
Are there any good (free or cheap) file comparison programs around that
work?
Thanks,
G
GaryB wrote:
> I scripted two versions of a database and then compared the text
> files using WinDiff. There were major differences in the two files
> but Windiff said they were the same "except for blanks." Has anyone
> else had such a problem with WinDiff?
> Are there any good (free or cheap) file comparison programs around
> that work?
> Thanks,
> G
Have you tried the command-line "fc.exe" that is bult into Windows. It
should be in the path, but on my XP system is located in the
WINDOWS\SYSTEM32 folder.
David Gugick
Imceda Software
www.imceda.com
|||Not with Windiff, but I've observed the problem with RedGate SQL Compare
where database objects show as the same but manual examination reveals
significant differences.
Michael D. Long
"GaryB" <gb@.nospam.com> wrote in message
news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
>I scripted two versions of a database and then compared the text files
>using
> WinDiff. There were major differences in the two files but Windiff said
> they were the same "except for blanks." Has anyone else had such a
> problem
> with WinDiff?
> Are there any good (free or cheap) file comparison programs around that
> work?
> Thanks,
> G
>
|||Would you be able to post some segments of text that aren't comparing
properly? I'm very surprised -- and disturbed -- to hear that Windiff isn't
reliable; it's quite an old product at this point, and I use it extensively
to compare source code. So I'd really like to know if it has deficiencies.
"GaryB" <gb@.nospam.com> wrote in message
news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
> I scripted two versions of a database and then compared the text files
using
> WinDiff. There were major differences in the two files but Windiff said
> they were the same "except for blanks." Has anyone else had such a
problem
> with WinDiff?
> Are there any good (free or cheap) file comparison programs around that
> work?
> Thanks,
> G
>
|||GaryB wrote:
> I scripted two versions of a database and then compared the text
> files using WinDiff. There were major differences in the two files
> but Windiff said they were the same "except for blanks." Has anyone
> else had such a problem with WinDiff?
> Are there any good (free or cheap) file comparison programs around
> that work?
> Thanks,
> G
I think the problem is that WinDiff is not designed for use with binary
files. It's an ASCII comparison tool. I would use fc.exe instead.
See this article:
http://support.microsoft.com/default...b;en-us;159214
David Gugick
Imceda Software
www.imceda.com
|||"David Gugick" <davidg-nospam@.imceda.com> wrote in message
news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
> I think the problem is that WinDiff is not designed for use with binary
> files. It's an ASCII comparison tool. I would use fc.exe instead.
Last time I checked, SQL Scripts are just text files. But I guess the
OP could have had them Unicode encoded?
Anyway, if you want a better diff/merge program than WinDiff, I highly
recommend Beyond Compare... fc.exe is rather ancient and difficult to use in
this age of Graphical User Interfaces...
http://www.scootersoftware.com/moreinfo.html
|||Adam Machanic wrote:
> "David Gugick" <davidg-nospam@.imceda.com> wrote in message
> news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
> Last time I checked, SQL Scripts are just text files. But I
> guess the OP could have had them Unicode encoded?
> Anyway, if you want a better diff/merge program than WinDiff, I
> highly recommend Beyond Compare... fc.exe is rather ancient and
> difficult to use in this age of Graphical User Interfaces...
> http://www.scootersoftware.com/moreinfo.html
I misread the OP. I thought he was comparing data files.
On another note, I use Beyond Compare as well and think it's a great
tool although I do find myself using FC.EXE on occasion for quick
comparisons.
David Gugick
Imceda Software
www.imceda.com
|||..sql files are text script files.
G
"David Gugick" <davidg-nospam@.imceda.com> wrote in message
news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
> GaryB wrote:
> I think the problem is that WinDiff is not designed for use with binary
> files. It's an ASCII comparison tool. I would use fc.exe instead.
> See this article:
> http://support.microsoft.com/default...b;en-us;159214
>
> --
> David Gugick
> Imceda Software
> www.imceda.com
>
|||Sorry but it is a script of our entire database that is propritary. one
data base had many tables missing, views missing, some column differences,
and stored procedures missing. WinDiff just pops up a dialog saying
difference in blanks only. I'm using WinDiff 5.1. I'll try tht Beyond
Compare.
G
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:uxnwyoEoEHA.3628@.TK2MSFTNGP09.phx.gbl...
> Would you be able to post some segments of text that aren't comparing
> properly? I'm very surprised -- and disturbed -- to hear that Windiff
> isn't
> reliable; it's quite an old product at this point, and I use it
> extensively
> to compare source code. So I'd really like to know if it has
> deficiencies.
>
> "GaryB" <gb@.nospam.com> wrote in message
> news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
> using
> problem
>
sqlsql

Comparing DBs with Windiff

I scripted two versions of a database and then compared the text files using
WinDiff. There were major differences in the two files but Windiff said
they were the same "except for blanks." Has anyone else had such a problem
with WinDiff?
Are there any good (free or cheap) file comparison programs around that
work?
Thanks,
GGaryB wrote:
> I scripted two versions of a database and then compared the text
> files using WinDiff. There were major differences in the two files
> but Windiff said they were the same "except for blanks." Has anyone
> else had such a problem with WinDiff?
> Are there any good (free or cheap) file comparison programs around
> that work?
> Thanks,
> G
Have you tried the command-line "fc.exe" that is bult into Windows. It
should be in the path, but on my XP system is located in the
WINDOWS\SYSTEM32 folder.
--
David Gugick
Imceda Software
www.imceda.com|||Not with Windiff, but I've observed the problem with RedGate SQL Compare
where database objects show as the same but manual examination reveals
significant differences.
--
Michael D. Long
"GaryB" <gb@.nospam.com> wrote in message
news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
>I scripted two versions of a database and then compared the text files
>using
> WinDiff. There were major differences in the two files but Windiff said
> they were the same "except for blanks." Has anyone else had such a
> problem
> with WinDiff?
> Are there any good (free or cheap) file comparison programs around that
> work?
> Thanks,
> G
>|||Would you be able to post some segments of text that aren't comparing
properly? I'm very surprised -- and disturbed -- to hear that Windiff isn't
reliable; it's quite an old product at this point, and I use it extensively
to compare source code. So I'd really like to know if it has deficiencies.
"GaryB" <gb@.nospam.com> wrote in message
news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
> I scripted two versions of a database and then compared the text files
using
> WinDiff. There were major differences in the two files but Windiff said
> they were the same "except for blanks." Has anyone else had such a
problem
> with WinDiff?
> Are there any good (free or cheap) file comparison programs around that
> work?
> Thanks,
> G
>|||GaryB wrote:
> I scripted two versions of a database and then compared the text
> files using WinDiff. There were major differences in the two files
> but Windiff said they were the same "except for blanks." Has anyone
> else had such a problem with WinDiff?
> Are there any good (free or cheap) file comparison programs around
> that work?
> Thanks,
> G
I think the problem is that WinDiff is not designed for use with binary
files. It's an ASCII comparison tool. I would use fc.exe instead.
See this article:
http://support.microsoft.com/default.aspx?scid=kb;en-us;159214
David Gugick
Imceda Software
www.imceda.com|||"David Gugick" <davidg-nospam@.imceda.com> wrote in message
news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
> I think the problem is that WinDiff is not designed for use with binary
> files. It's an ASCII comparison tool. I would use fc.exe instead.
Last time I checked, SQL Scripts are just text files. But I guess the
OP could have had them Unicode encoded?
Anyway, if you want a better diff/merge program than WinDiff, I highly
recommend Beyond Compare... fc.exe is rather ancient and difficult to use in
this age of Graphical User Interfaces...
http://www.scootersoftware.com/moreinfo.html|||For tools, I would check out Innovartis DB Ghost
http://www.innovartis.co.uk/
Regards,
Nick Evans
>--Original Message--
>I scripted two versions of a database and then compared
the text files using
>WinDiff. There were major differences in the two files
but Windiff said
>they were the same "except for blanks." Has anyone else
had such a problem
>with WinDiff?
>Are there any good (free or cheap) file comparison
programs around that
>work?
>Thanks,
>G
>
>.
>|||Adam Machanic wrote:
> "David Gugick" <davidg-nospam@.imceda.com> wrote in message
> news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
>> I think the problem is that WinDiff is not designed for use with
>> binary files. It's an ASCII comparison tool. I would use fc.exe
>> instead.
> Last time I checked, SQL Scripts are just text files. But I
> guess the OP could have had them Unicode encoded?
> Anyway, if you want a better diff/merge program than WinDiff, I
> highly recommend Beyond Compare... fc.exe is rather ancient and
> difficult to use in this age of Graphical User Interfaces...
> http://www.scootersoftware.com/moreinfo.html
I misread the OP. I thought he was comparing data files.
On another note, I use Beyond Compare as well and think it's a great
tool although I do find myself using FC.EXE on occasion for quick
comparisons.
David Gugick
Imceda Software
www.imceda.com|||.sql files are text script files.
G
"David Gugick" <davidg-nospam@.imceda.com> wrote in message
news:esqkY7FoEHA.1152@.TK2MSFTNGP11.phx.gbl...
> GaryB wrote:
>> I scripted two versions of a database and then compared the text
>> files using WinDiff. There were major differences in the two files
>> but Windiff said they were the same "except for blanks." Has anyone
>> else had such a problem with WinDiff?
>> Are there any good (free or cheap) file comparison programs around
>> that work?
>> Thanks,
>> G
> I think the problem is that WinDiff is not designed for use with binary
> files. It's an ASCII comparison tool. I would use fc.exe instead.
> See this article:
> http://support.microsoft.com/default.aspx?scid=kb;en-us;159214
>
> --
> David Gugick
> Imceda Software
> www.imceda.com
>|||Sorry but it is a script of our entire database that is propritary. one
data base had many tables missing, views missing, some column differences,
and stored procedures missing. WinDiff just pops up a dialog saying
difference in blanks only. I'm using WinDiff 5.1. I'll try tht Beyond
Compare.
G
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:uxnwyoEoEHA.3628@.TK2MSFTNGP09.phx.gbl...
> Would you be able to post some segments of text that aren't comparing
> properly? I'm very surprised -- and disturbed -- to hear that Windiff
> isn't
> reliable; it's quite an old product at this point, and I use it
> extensively
> to compare source code. So I'd really like to know if it has
> deficiencies.
>
> "GaryB" <gb@.nospam.com> wrote in message
> news:ubOAitAoEHA.2804@.TK2MSFTNGP09.phx.gbl...
>> I scripted two versions of a database and then compared the text files
> using
>> WinDiff. There were major differences in the two files but Windiff said
>> they were the same "except for blanks." Has anyone else had such a
> problem
>> with WinDiff?
>> Are there any good (free or cheap) file comparison programs around that
>> work?
>> Thanks,
>> G
>>
>

Comparing DBs

is there any utility or program available that will compare two versions of
the same SQL Server database in terms of definition and objects. I don't
want to compare data. I need to see the differences in tables columns views
etc.
Thanks,
GaryThere are quite a few companies that make such products. Check out this
list: http://vyaskn.tripod.com/thirdparty.htm
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
Is .NET important for a database professional?
http://vyaskn.tripod.com/poll.htm
"Gary" <gb@.nospam.com> wrote in message
news:ewGG5cf2DHA.2308@.TK2MSFTNGP11.phx.gbl...
is there any utility or program available that will compare two versions of
the same SQL Server database in terms of definition and objects. I don't
want to compare data. I need to see the differences in tables columns views
etc.
Thanks,
Gary|||We use the following tool
http://www.adeptsql.com/
Its cheap, very accurate, very fast and will also update
your out of sync database if you wish. There is also a
trial version which you can download.
J
>--Original Message--
>is there any utility or program available that will
compare two versions of
>the same SQL Server database in terms of definition and
objects. I don't
>want to compare data. I need to see the differences in
tables columns views
>etc.
>Thanks,
>Gary
>
>.
>|||We use ERWin by Computer Associates.
a bit spendy but it does More then just compare Databases.
http://www3.ca.com/Solutions/Product.asp?ID=260
Gregory A Jackson
PDX, Oregon|||Hi Gary,
Thank you for using MSDN Newsgroup! It's my pleasure to assist you with
your issue.
For your question of compare the two versions of the same SQL Server
database in terms of definitions and objects but not data in them. Besides
the utiltities suggested by our MVPs and community members, if the compare
is quite simple, you can just generate a 'script' that define the objects
in 2 SQL Server respectively and compare the script. To generate the
script, they can use SQL Enterprise Manager and choose the "Object|Generate
SQL Script..." menu item. Another way is to use 'sp_help' upon each object
in the 2 database and compare them.
Hope this helps. If you still have questions on this issue, please feel
free to post new message here and I am ready to help!
Best regards
Baisong Wei
Microsoft Online Support
----
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only. Thanks.|||Hi Gary,
As said in the answers, you can use tools to compare the databases.
I prefer to use the sysobjects table to do that, simply by doing
a
SELECT * from db1.sysobjects where not in (SELECT * from db2.sysobjects)
or
SELECT * from db2.sysobjects where not in (SELECT * from db1.sysobjects)
This works if you want to analyse the difference in term of tables
and fields.
To have a deeper analysis (fields of different types) it is more difficult
but possible with other system tables like syscolumns.
Gilles
"Gary" <gb@.nospam.com> wrote in message news:<ewGG5cf2DHA.2308@.TK2MSFTNGP11.phx.gbl>...
> is there any utility or program available that will compare two versions of
> the same SQL Server database in terms of definition and objects. I don't
> want to compare data. I need to see the differences in tables columns views
> etc.
> Thanks,
> Gary|||also check out DB Ghost @. www.dbghost.com
regards,
Mark Baekdal
>--Original Message--
>is there any utility or program available that will
compare two versions of
>the same SQL Server database in terms of definition and
objects. I don't
>want to compare data. I need to see the differences in
tables columns views
>etc.
>Thanks,
>Gary
>
>.
>|||I downloaded it and tried it out. Works great. Many thanks.
Gary
"Julie" <anonymous@.discussions.microsoft.com> wrote in message
news:0d0601c3d9fa$103b29b0$a601280a@.phx.gbl...
> We use the following tool
> http://www.adeptsql.com/
> Its cheap, very accurate, very fast and will also update
> your out of sync database if you wish. There is also a
> trial version which you can download.
> J
>
> >--Original Message--
> >is there any utility or program available that will
> compare two versions of
> >the same SQL Server database in terms of definition and
> objects. I don't
> >want to compare data. I need to see the differences in
> tables columns views
> >etc.
> >Thanks,
> >Gary
> >
> >
> >.
> >

Comparing DBs

We use the following tool
http://www.adeptsql.com/
Its cheap, very accurate, very fast and will also update
your out of sync database if you wish. There is also a
trial version which you can download.
J
quote:

>--Original Message--
>is there any utility or program available that will

compare two versions of
quote:

>the same SQL Server database in terms of definition and

objects. I don't
quote:

>want to compare data. I need to see the differences in

tables columns views
quote:

>etc.
>Thanks,
>Gary
>
>.
>
I downloaded it and tried it out. Works great. Many thanks.
Gary
"Julie" <anonymous@.discussions.microsoft.com> wrote in message
news:0d0601c3d9fa$103b29b0$a601280a@.phx.gbl...[QUOTE]
> We use the following tool
> http://www.adeptsql.com/
> Its cheap, very accurate, very fast and will also update
> your out of sync database if you wish. There is also a
> trial version which you can download.
> J
>
> compare two versions of
> objects. I don't
> tables columns views

Comparing DBs

is there any utility or program available that will compare two versions of
the same SQL Server database in terms of definition and objects. I don't
want to compare data. I need to see the differences in tables columns views
etc.
Thanks,
GaryThere are quite a few companies that make such products. Check out this
list: http://vyaskn.tripod.com/thirdparty.htm
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
Is .NET important for a database professional?
http://vyaskn.tripod.com/poll.htm
"Gary" <gb@.nospam.com> wrote in message
news:ewGG5cf2DHA.2308@.TK2MSFTNGP11.phx.gbl...
is there any utility or program available that will compare two versions of
the same SQL Server database in terms of definition and objects. I don't
want to compare data. I need to see the differences in tables columns views
etc.
Thanks,
Gary|||We use ERWin by Computer Associates.
a bit spendy but it does More then just compare Databases.
http://www3.ca.com/Solutions/Product.asp?ID=260
Gregory A Jackson
PDX, Oregon|||Hi Gary,
Thank you for using MSDN Newsgroup! It's my pleasure to assist you with
your issue.
For your question of compare the two versions of the same SQL Server
database in terms of definitions and objects but not data in them. Besides
the utiltities suggested by our MVPs and community members, if the compare
is quite simple, you can just generate a 'script' that define the objects
in 2 SQL Server respectively and compare the script. To generate the
script, they can use SQL Enterprise Manager and choose the "Object|Generate
SQL Script..." menu item. Another way is to use 'sp_help' upon each object
in the 2 database and compare them.
Hope this helps. If you still have questions on this issue, please feel
free to post new message here and I am ready to help!
Best regards
Baisong Wei
Microsoft Online Support
----
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only. Thanks.|||Hi Gary,
As said in the answers, you can use tools to compare the databases.
I prefer to use the sysobjects table to do that, simply by doing
a
SELECT * from db1.sysobjects where not in (SELECT * from db2.sysobjects)
or
SELECT * from db2.sysobjects where not in (SELECT * from db1.sysobjects)
This works if you want to analyse the difference in term of tables
and fields.
To have a deeper analysis (fields of different types) it is more difficult
but possible with other system tables like syscolumns.
Gilles
"Gary" <gb@.nospam.com> wrote in message news:<ewGG5cf2DHA.2308@.TK2MSFTNGP11.phx.gbl>...
quote:
[col
or=darkred]
> is there any utility or program available that will compare two versions o
f
> the same SQL Server database in terms of definition and objects. I don't
> want to compare data. I need to see the differences in tables columns vie
ws
> etc.
> Thanks,
> Gary[/color]
sqlsql

Tuesday, March 20, 2012

Comparing 2 dbs for differences in column definitions

Hi All
I have 2 dbs, one for prodcution and the other one for development
environment. They are meant to be the same.
Is there a script/way to compare the dbs for any difference in column
datatypes, length.
This query has what i want to compare:
select
table_name, column_name, data_type, character_maximum_length [Length],
is_nullable [Null], numeric_precision NuPrec, numeric_scale NuScal,
datetime_precision DTPrec
from
information_schema.columns
order by table_name ASC, column_name ASC
Thank you on advance.Maybe you should take a look at Red Gate's SQL Compare.
http://www.red-gate.com/
ML
http://milambda.blogspot.com/|||See replies to the post "Comparing two databases".
"MittyKom" <MittyKom@.discussions.microsoft.com> wrote in message
news:844E5968-C506-4A25-A410-2128BA6F2741@.microsoft.com...
> Hi All
> I have 2 dbs, one for prodcution and the other one for development
> environment. They are meant to be the same.
> Is there a script/way to compare the dbs for any difference in column
> datatypes, length.
> This query has what i want to compare:
> select
> table_name, column_name, data_type, character_maximum_length [Length],
> is_nullable [Null], numeric_precision NuPrec, numeric_scale NuScal,
> datetime_precision DTPrec
> from
> information_schema.columns
> order by table_name ASC, column_name ASC
> Thank you on advance.
>

Monday, March 19, 2012

Compare Tables?

Hello. I have two copies of a database (one older, one newer). I
would like to compare them and take the records that do not appear in
both dbs and copy them to the newer one.
As much as I would like to manually go through, row by row, is there
an easier way'
Using:
- SQL 7
- Win NT
Many thanks!
JDThere's a 3rd party product called SQLCompare...
--
HTH
Ryan Waight, MCDBA, MCSE
"JD" <whatchoogot@.hotmail.com> wrote in message
news:b809817a.0311120722.5bcbac2f@.posting.google.com...
> Hello. I have two copies of a database (one older, one newer). I
> would like to compare them and take the records that do not appear in
> both dbs and copy them to the newer one.
> As much as I would like to manually go through, row by row, is there
> an easier way'
> Using:
> - SQL 7
> - Win NT
> Many thanks!
> JD|||JD,
I have used this product it great but becareful because
it will lock the table during comparing. It best that
you don't do this in production server.
Take Care,
Rachan
>--Original Message--
>There's a 3rd party product called SQLCompare...
>--
>HTH
>Ryan Waight, MCDBA, MCSE
>"JD" <whatchoogot@.hotmail.com> wrote in message
>news:b809817a.0311120722.5bcbac2f@.posting.google.com...
>> Hello. I have two copies of a database (one older,
one newer). I
>> would like to compare them and take the records that
do not appear in
>> both dbs and copy them to the newer one.
>> As much as I would like to manually go through, row by
row, is there
>> an easier way'
>> Using:
>> - SQL 7
>> - Win NT
>> Many thanks!
>> JD
>
>.
>|||Also a 3rd party tool called DB Ghost at www.dbghost.com
Thanks,
Darren Fuller MCSE
>--Original Message--
>Hello. I have two copies of a database (one older, one
newer). I
>would like to compare them and take the records that do
not appear in
>both dbs and copy them to the newer one.
>As much as I would like to manually go through, row by
row, is there
>an easier way'
>Using:
>- SQL 7
>- Win NT
>Many thanks!
>JD
>.
>