Hi,
I have a old VC++ application using DB-Library for connection with sqlserver
6.5. Recently I have migrated the sqlserver from 6.5 to 2000. during
recompilation of the vc++ code, i have a problem with ntwdblib.lib file. I
think it does not match with the SQL 2000 version one.
The SQL 2000 installation CD ships with :-
- ntwdblib.lib | dated:Sunday, August 06, 2000, 8:30:29 AM | 31 kb
- ntwlib.dll | ver:2000.80.194.0 | dated: Sunday, August 06, 2000, 9:51:53
AM | 269kb
Post SQL 2000SP4 installation :-
- ntwlib.dll | ver:2000.80.2039.0 | dated: Wednesday, May 04, 2005, 12:02:26
AM | 284 kb
Currently, I have SQL 2000 SP4 installed.
Please advice me, where can i get the NTWDBLIB.LIB file correponding the
NTWDBLIB.DLL which ships with SP4
Regards,
--ChanduChandu (Chandu@.discussions.microsoft.com) writes:
> I have a old VC++ application using DB-Library for connection with
> sqlserver 6.5. Recently I have migrated the sqlserver from 6.5 to 2000.
> during recompilation of the vc++ code, i have a problem with
> ntwdblib.lib file. I think it does not match with the SQL 2000 version
> one.
> The SQL 2000 installation CD ships with :-
> - ntwdblib.lib | dated:Sunday, August 06, 2000, 8:30:29 AM | 31 kb
> - ntwlib.dll | ver:2000.80.194.0 | dated: Sunday, August 06, 2000, 9:51:53
> AM | 269kb
> Post SQL 2000SP4 installation :-
> - ntwlib.dll | ver:2000.80.2039.0 | dated: Wednesday, May 04, 2005,
> 12:02:26 AM | 284 kb
> Currently, I have SQL 2000 SP4 installed.
> Please advice me, where can i get the NTWDBLIB.LIB file correponding the
> NTWDBLIB.DLL which ships with SP4
What problem do you see? Since Microsofr hardly touches DB-Library at
all these days, I see no reason to assume that the RTM LIB file should
not be OK with the SP4 DLL. I checked on my machine, and I don't have
any newer version of NTWDBLIB.LIB that the one you mention.
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx|||Thanks Erland for the reply,
You are right the NTWDBLIB has not changed, the problem is with the linker
of VC++5.0, it needed an upgrade. It works fine now.
thanks,
"Erland Sommarskog" wrote:
> Chandu (Chandu@.discussions.microsoft.com) writes:
> What problem do you see? Since Microsofr hardly touches DB-Library at
> all these days, I see no reason to assume that the RTM LIB file should
> not be OK with the SP4 DLL. I checked on my machine, and I don't have
> any newer version of NTWDBLIB.LIB that the one you mention.
>
> --
> Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
> Books Online for SQL Server 2005 at
> http://www.microsoft.com/technet/pr...oads/books.mspx
> Books Online for SQL Server 2000 at
> http://www.microsoft.com/sql/prodin...ions/books.mspx
>
Showing posts with label sqlserver. Show all posts
Showing posts with label sqlserver. Show all posts
Tuesday, February 14, 2012
Sunday, February 12, 2012
Compatibility between installation of MSDE 2000 and SQLServer 7
I want to install MSDE 2000 rel A on a Windows Server 2000 where SQLServer 7
is installed.
CAn I do it? Can MSDE and SQLServer live together?
Must I do any action before to install MSDE?
Thank you in advance
enzo giurleo
hi Enzo,
Enzo Giurleo wrote:
> I want to install MSDE 2000 rel A on a Windows Server 2000 where
> SQLServer 7 is installed.
> CAn I do it? Can MSDE and SQLServer live together?
> Must I do any action before to install MSDE?
> Thank you in advance
> enzo giurleo
you can install MSDE 2000 on a pc already hosting SQL Server 7.0..
SQL Server 7.0 will be the default instance, as it does not support multiple
instances, while MSDE will become a named instance you have to connect to
using the <computername>\<instancename> syntax but...
but...
MSDE 2000 will install and register it's own part of the shared component,
such as SQL-DMO and so on, and it does not contain the full client tools
like Enterprise Manager, Query Analyzer, Profiler and so on, so you loose
the possibility to administer your SQL Server 7.0 with your original 7.0
tools...
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtmhttp://italy.mvps.org
DbaMgr2k ver 0.9.1 - DbaMgr ver 0.55.1
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
-- remove DMO to reply
is installed.
CAn I do it? Can MSDE and SQLServer live together?
Must I do any action before to install MSDE?
Thank you in advance
enzo giurleo
hi Enzo,
Enzo Giurleo wrote:
> I want to install MSDE 2000 rel A on a Windows Server 2000 where
> SQLServer 7 is installed.
> CAn I do it? Can MSDE and SQLServer live together?
> Must I do any action before to install MSDE?
> Thank you in advance
> enzo giurleo
you can install MSDE 2000 on a pc already hosting SQL Server 7.0..
SQL Server 7.0 will be the default instance, as it does not support multiple
instances, while MSDE will become a named instance you have to connect to
using the <computername>\<instancename> syntax but...
but...
MSDE 2000 will install and register it's own part of the shared component,
such as SQL-DMO and so on, and it does not contain the full client tools
like Enterprise Manager, Query Analyzer, Profiler and so on, so you loose
the possibility to administer your SQL Server 7.0 with your original 7.0
tools...
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtmhttp://italy.mvps.org
DbaMgr2k ver 0.9.1 - DbaMgr ver 0.55.1
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
-- remove DMO to reply
Friday, February 10, 2012
Comparing two tables
IS there an easy way to compare two tables in sqlserver? I only need to display items that are different between table a and b.
thanks in advance for your help!One quick way is to use EM to script each table then compare both files.|||I was referring to the data in the tables. Sorry for the confusion.|||If you know perl, you should do it with a script like that:
#!C:/Perl/bin/perl.exe
# SYNTAXE : perl script.pl server db user pwd
use DBI;
my @.param = @.ARGV;
my $server = $param[0];
my $database = $param[1];
my $user = $param[2];
my $password = $param[3];
my $dsn = "Driver={SQL Server};Server=$server;Database=$database;Uid=$use r;Pwd=$password;" ;
my $dbh = DBI->connect("dbi:ADO:$dsn") or die "Impossible connection: $DBI::errstr";
my $sth1 = $dbh->prepare( q{
SELECT * FROM table1
}) or die "Can't prepare statement: $DBI::errstr";
my $sth2 = $dbh->prepare( q{
SELECT * FROM table2
}) or die "Can't prepare statement: $DBI::errstr";
my $rc1 = $sth1->execute
or die "Can't execute statement: $DBI::errstr";
my $rc2 = $sth1->execute
or die "Can't execute statement: $DBI::errstr";
while ( @.row1 = $sth1->fetchrow_array and @.row2 = $sth2->fetchrow_array )
{
# do your tests here
}
$rc = $dbh->disconnect;|||Sorry, I don't know pearl. Is there anything on sqlserver?|||Don't see what, except a sql script that you have to write (like the one in perl) :)|||IS there an easy way to compare two tables in sqlserver? I only need to display items that are different between table a and b.
thanks in advance for your help!What exactly do you mean by "items"? Do your tables have Primary Keys (if not, this problems gets incredibly ugly)? What exactly do you want displayed when a difference is found?
The best bet might be to compose a sample set of data that contains a pair of 5 row tables with one row "missing" in each of them, and the output that you'd like to get from comparing them.
-PatP|||You mean like
USE Northwind
GO
SET NOCOUNT ON
CREATE TABLE myTable99(Col1 int IDENTITY(1,1) PRIMARY KEY, Col2 char(1))
CREATE TABLE myTable00(Col1 int IDENTITY(1,1) PRIMARY KEY, Col2 char(1))
GO
INSERT INTO myTable99(Col2)
SELECT 'a' UNION ALL
SELECT 'b' UNION ALL
SELECT 'c' UNION ALL
SELECT 'd'
INSERT INTO myTable00(Col2)
SELECT 'a' UNION ALL
SELECT 'x' UNION ALL
SELECT 'c' UNION ALL
SELECT 'z'
GO
SELECT a.Col1, a.Col2, b.Col2
FROM myTable99 a
INNER JOIN myTable00 b
ON a.Col1 = b.Col1
WHERE a.Col2 <> b.Col2
GO
SET NOCOUNT OFF
DROP TABLE myTable99
DROP TABLE myTable00
GO|||Try this:
http://www.sqlservercentral.com/scripts/contributions/596.asp|||Ummm ... isn't it much easier than that? How about
SELECT value1, value2, value3, value4, value5
FROM table1
WHERE value1 NOT IN (SELECT value1 FROM table2)
thanks in advance for your help!One quick way is to use EM to script each table then compare both files.|||I was referring to the data in the tables. Sorry for the confusion.|||If you know perl, you should do it with a script like that:
#!C:/Perl/bin/perl.exe
# SYNTAXE : perl script.pl server db user pwd
use DBI;
my @.param = @.ARGV;
my $server = $param[0];
my $database = $param[1];
my $user = $param[2];
my $password = $param[3];
my $dsn = "Driver={SQL Server};Server=$server;Database=$database;Uid=$use r;Pwd=$password;" ;
my $dbh = DBI->connect("dbi:ADO:$dsn") or die "Impossible connection: $DBI::errstr";
my $sth1 = $dbh->prepare( q{
SELECT * FROM table1
}) or die "Can't prepare statement: $DBI::errstr";
my $sth2 = $dbh->prepare( q{
SELECT * FROM table2
}) or die "Can't prepare statement: $DBI::errstr";
my $rc1 = $sth1->execute
or die "Can't execute statement: $DBI::errstr";
my $rc2 = $sth1->execute
or die "Can't execute statement: $DBI::errstr";
while ( @.row1 = $sth1->fetchrow_array and @.row2 = $sth2->fetchrow_array )
{
# do your tests here
}
$rc = $dbh->disconnect;|||Sorry, I don't know pearl. Is there anything on sqlserver?|||Don't see what, except a sql script that you have to write (like the one in perl) :)|||IS there an easy way to compare two tables in sqlserver? I only need to display items that are different between table a and b.
thanks in advance for your help!What exactly do you mean by "items"? Do your tables have Primary Keys (if not, this problems gets incredibly ugly)? What exactly do you want displayed when a difference is found?
The best bet might be to compose a sample set of data that contains a pair of 5 row tables with one row "missing" in each of them, and the output that you'd like to get from comparing them.
-PatP|||You mean like
USE Northwind
GO
SET NOCOUNT ON
CREATE TABLE myTable99(Col1 int IDENTITY(1,1) PRIMARY KEY, Col2 char(1))
CREATE TABLE myTable00(Col1 int IDENTITY(1,1) PRIMARY KEY, Col2 char(1))
GO
INSERT INTO myTable99(Col2)
SELECT 'a' UNION ALL
SELECT 'b' UNION ALL
SELECT 'c' UNION ALL
SELECT 'd'
INSERT INTO myTable00(Col2)
SELECT 'a' UNION ALL
SELECT 'x' UNION ALL
SELECT 'c' UNION ALL
SELECT 'z'
GO
SELECT a.Col1, a.Col2, b.Col2
FROM myTable99 a
INNER JOIN myTable00 b
ON a.Col1 = b.Col1
WHERE a.Col2 <> b.Col2
GO
SET NOCOUNT OFF
DROP TABLE myTable99
DROP TABLE myTable00
GO|||Try this:
http://www.sqlservercentral.com/scripts/contributions/596.asp|||Ummm ... isn't it much easier than that? How about
SELECT value1, value2, value3, value4, value5
FROM table1
WHERE value1 NOT IN (SELECT value1 FROM table2)
Subscribe to:
Posts (Atom)