Board index » delphi » How do I connect to SQL Server 2000 with the BDE

How do I connect to SQL Server 2000 with the BDE

I am using D5 and BDE 5.11 on Windows 2000 sp3

How do I connect to, let's say the northwnd database.?

What are the actual steps required?

I created a User DSN for SQL Server 2000 and the test there shows that it
connects.

Now, what do I do from here to make it work?

Thanks in advance,

S. Adams

 

Re:How do I connect to SQL Server 2000 with the BDE


If you have D5 Enterprise your best bet is to use ADO.
If you have D5 Professional I believe there is an add on for ADO.

ADO will make your life much easier in connecting to SQL Server 2000.

HTH
Ross

Re:How do I connect to SQL Server 2000 with the BDE


hmmm...that doesn't answer the question, does it?
i also want to connect to MSSQL2K but not
to develop an app but to use the DBExplorer with.
and that needs to pass thru BDE.

Quote
"Ross" <polk...@hotmail.com> wrote in message

news:3DC9944D.3060006@hotmail.com...
Quote

> If you have D5 Enterprise your best bet is to use ADO.
> If you have D5 Professional I believe there is an add on for ADO.

> ADO will make your life much easier in connecting to SQL Server 2000.

> HTH
> Ross

Re:How do I connect to SQL Server 2000 with the BDE


One can use BDE --> ODBC --> SQL Server

In addition, if one has a SQL Server license, one can distribute
the MSDE (5 -user desktop version of SQL Server 7 or 2000) which
allows a database to be up to 2GB in size.  As such, your
clients can test your software out if you use SQL Server.

Good luck.

Gene

Quote
"S. Adams" <nom...@nomail.com> wrote in message

news:3dc9b653@newsgroups.borland.com...
Quote
> Hi Ross,

> The problem is I do not want to rewrite our application...  We currently
> sell our application as a single, network, and Client / Server
application.
> The average customer purchases are for a basic document management system
> and require only the paradox database.  There is about a 10% request for a
> more robust system as in using MS SQL or Oracle.

> The current application is in use by more than 300 customers.  I don't
want
> to be the one to tell them that they need to purchase, install and
maintain
> MS SQL.

> And, some of the existing customers actually use the paradox database as a
> private base on their workstation and when they are ready to move the
> documents to the server they simply drag them into the C/S database on the
> main server.  (This is a function of the application).

> The application manages multiple connections to different database types.

> The biggest problem in selling a commercial product, is the prospective
> buyers want a quick and easy way to evaluate the product before they
> puchase, requiring MS SQL as  a base would be out of the question.

> So, any help specifically on how to connect to SQL Server 2000 with the
BDE
> would be greatly appriciated!

> Thanks in advance,

> S. Adams

Re:How do I connect to SQL Server 2000 with the BDE


S. Adams,

If you have D5 Enterprise you could :
1. Create a MSSQL BDE Alias in the BDE Administrator
    - Set the Database Name, Server Name accordingly
2  Drop a TDatabase onto a form/datamodule, select it's AliasName property
to your new Alias
3. Set your TQuery's DatabaseName property (dropdown) to your
TDatabase.DatabaseName property
4. Write some SQL, set Active to True,  and your good to go.

Obviously there is a lot more involved (do you have a MSSQL database?  do
you have the MSSQL client drivers installed, etc) and require more than a
couple of paragraphs.

Head over to http://community.borland.com/ or more specifically
http://community.borland.com/delphi/database/0,1418,10004,00.html
and check out the many articles on client/server development
(http://bdn.borland.com/article/0,1410,28160,00.html is a good one)

Good luck,
krf

Quote
"S. Adams" <nom...@nomail.com> wrote in message

news:3dc9b653@newsgroups.borland.com...
Quote
> Hi Ross,

> The problem is I do not want to rewrite our application

Re:How do I connect to SQL Server 2000 with the BDE


I not sure, but to BDE connect on MSSQL, you have to install SQL Server
Client on the workstation

That's why the 'vendor initialization failed' apears.

Or you can copy that DLL, I don't know if will need any other file.

"S. Adams" <nom...@nomail.com> escreveu na mensagem
news:3dcb0989@newsgroups.borland.com...

Quote
> Hi Kevin,

> I am completely confused!

> > If you have D5 Enterprise you could :
> I do!

> > 1. Create a MSSQL BDE Alias in the BDE Administrator
> >     - Set the Database Name, Server Name accordingly

> According to what?  The only server name that appears is 'MSS_SERVER'

> If I try to open the database with the default server name 'MSS_SERVER'
then
> I get the errors:
> 'Vendor initialization failed.'
> 'File: NTWDBLIB.DLL'
> 'Alias: MSSQL1'

> > Obviously there is a lot more involved (do you have a MSSQL database?
do
> > you have the MSSQL client drivers installed, etc) and require more than
a
> > couple of paragraphs.

> What do you mean by "do you have a MSSQL database?"

> As stated in my original message... I installed the SQL Server 2000 on one
> workstation (call this on the server) and I run my application on a
> different workstation.

> The only way I could see to access the SQL Server 2000 was by creating a
> DSN.

> Am I wrong, or is there another way?

> Thanks in advance,

> S. Adams

Re:How do I connect to SQL Server 2000 with the BDE


Quote
> I have the SQL Server2000 Enterprise Edition (Evaluation CD)
> How do I install the client side?  Do I have to install the server on my
> local workstation?
> I don't see any client side install on the CD.

Run the Enterprise setup on the client. It will detect that the computer
is not 2000 Server and only allow to install the client utilities.
One of the options is to install Enterprise Manager on the client.

Quote
> Yes, I created an empty database.  I want to use the datapump utilitiy to
> create the tables from an existing paradox structure.
> We did it this way a few years back for a client to move them into MSSQL
> 6.5.

  Should work... If you have a BDE Alias set up as described earlier.

I used a Data Transformation Services Package in SQL Server instead of
the Datapump. DTS Packages are a bit advanced though.

Quote
> If I was to move to ADO, how much of a rewrite of an existing application
> using the BDE would it be?
> Can ADO access Paradox files and read and write blob fields?

I did it last year. I went through all the datamodules and replaced all
queries with an ADODataset of the same name. There were only a few items
I had to rewrite, different implentations of methods.
I don't know if it will read Paradox Files.
I have not had a problem with blobl fields.

Ross

Re:How do I connect to SQL Server 2000 with the BDE


S. Adams

Quote
"S. Adams" <nom...@nomail.com> wrote in message

news:3dcb0989@newsgroups.borland.com...

Quote
> According to what?  The only server name that appears is 'MSS_SERVER'

Yes,  type the server name (or IP address) of the machine running the MSSQL
service

Quote
> If I try to open the database with the default server name 'MSS_SERVER'
then
> I get the errors:
> 'Vendor initialization failed.'
> 'File: NTWDBLIB.DLL'
> 'Alias: MSSQL1'

You don't have the MSSQL clients installed.  Once you install the client,
create a connection to the server/instance, then create the BDE alias.

Quote
> > Obviously there is a lot more involved (do you have a MSSQL database?
do
> > you have the MSSQL client drivers installed, etc) and require more than
a
> > couple of paragraphs.

> What do you mean by "do you have a MSSQL database?"
> As stated in my original message... I installed the SQL Server 2000 on one
> workstation (call this on the server) and I run my application on a
> different workstation.

Installing the server doesn't create the database.  Did you create a
database?  Do you create the necessary tables?  Do the tables contain data?

Quote
> The only way I could see to access the SQL Server 2000 was by creating a
> DSN.

> Am I wrong, or is there another way?

There is more than one way to skin a cat, but since you have D5 Enterprise
use the native MSSQL links that are included with the BDE.  Just FYI,
Microsoft no longer supports the DBLib (which the BDE uses) in favor of ADO
(OLE-DB) and Borland has dropped further development of the BDE.
Quote
> Thanks in advance,

> S. Adams

Re:How do I connect to SQL Server 2000 with the BDE


Hi Kevin.. thanks for your responses also...

See my post response to Ross...

Quote
> Avoid using DataPump.  Use MSSQL's DTS (Data Transformation Services),
it's
> highly configurable, fast, and fast (so nice I had to say it twice).   For
a
> one time data move, DataPump should be fine, but definitely not something
to
> use in a production environment (bad experiences from MSSQL 6.5)

This would be a one time only thing.

Quote
> ADO is a different animal than the BDE.  In some ways better, in some ways
> worse.  From my experience, it's not a db engine issue, but more of an
> application design issue.  Desktop dbs and SQL based server work
> differently, so therefore the "behind the scenes" code has to be
different.
> The article, http://bdn.borland.com/article/0,1410,28160,00.html does a
> great job of explaining some important differences.
> For my applications, switching the BDE to ADO will be nearly transparent,
> little or no code to change.  Why?  The server does most of the work
through
> views, triggers, stored procedures, etc.  If I had to modify our customer
> service application to work with Paradox, then yea, it's a
rewrite...Oracle,
> Interbase...nothing.

Ross did not know, maybe you do,  can you use ADO to connect to Paradox
tables and if so are there any problems with accessing the blob fields?

Thanks again,

S. Adams

Other Threads