Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    Visual Basic




How To Connect To Interbase Database?


How do I connect to a interbase database (*.gdb) under VB environment? Can I use control like data grid, data combo, ado control to manipulate this database? Please help. Thank you.




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Need To Connect To Interbase Database?
Hi There,
How can i connect to interbase database with code?
I tried this;

Dim cnn As New ADODB.Connection

path= "D:YNPALLOZTAY_DATA_270406pdks.gdb"
Adodc1.ConnectionString=path
cnn.ConnectionString = Adodc1.ConnectionString
cnn.Open , "SYSDBA", "masterkey"

but it doesnt work.There is an error.
Please help me



How Can I Connect With InterBase 6 Using ADO?
Hi Friends,

How can I establish a connection with Borland InterBase 6 by using ADO and where can I download Interbase 6 ODBC driver?

Thanks for any help,
Fernando.

How To Connect Vb To Interbase?
hello
 can anyone help me..

i dont know vb yet but its my project to do so..

how can i connect vb to interbase to get the data from the interbase?


r3sann

Please Help Me . Problem:-Getting Data From Interbase Using Access Database Dynamically
Hello,
I am using Visual Basic6.0 as frontend,MS Access 2000 and Interbase as Backend and Crystal Reports as reporting tool.For reporting purpose I have written pass-thru queries in Access to get the data residing in Interbase.How can I change the odbc connect str property of the pass-thru query programmatically so that i can pass the username and password to the query during program execution.
The requirement is very urgent.Please give me a feasible solution as soon as possible
Thank You
Nivedita

VB And Interbase....
Hey guys!

Anyone knows what should I do to connect Visual basic to an Interbase database? I just know how to connect to access.. =-(


Thanks guys!

Elminster

Please Help With Vb & Interbase
Did anybody have some code shippet about visual basic and Interbase? I know how to connect with database, but I have big problems with stored procedures with output parameters. Any links or code snippets will be a great help.

regards

InterBase 5.5
Can Any body help me on InterBase Problems.. I have used this DataBase for More than 10 Clients and its creating problem.

AITG

Interbase Decent ADO
hi

the past month every now and then i have asked about interbase. and from viewing some of the threads i noticed there is not a lot of people that works with inter base. i would like to know if anyone has got a decent, not full of crap, not full of bugs ADO provider for interbase and that is FREE(why free, because the South African RAND is not a strong currency and my salary does not provide sufficient funds to by a $30 provider) or if anyone can give me tips on how to write my own ADO.

Interbase 2 Things
Can anyone tell me where could i download an ODBC to connect a VB app to interbase?

I had tried everything SEARCH on the web
I am have interbase 6.0 but if i can download 6.5 you can tell me where

VB.NET And Interbase Problems
Im doing a project in VB.NET using an INTERBASE database..

I'm able to show the info in the DB using the following code :

Dim cN As New ADODB.Connection()
Dim rS As New ADODB.Recordset()

cN.ConnectionString = "provider=LCPI.IBProvider;data source=localhost:" & _
"C:DINEM.gdb;ctype=" & _
"win1251;user id=SYSDBA;password=masterkey"

cN.Open()

rS.ActiveConnection = cN

cN.BeginTrans()

rS.Open("SELECT * FROM CUSTOMERS", cN, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockOptimistic)
rS.MoveFirst()



My problem is when I try to update, delete or add - I get the following error message :

Additional information: Current Recordset does not support updating. This may be a limitation of the provider, or of the selected locktype.

I have changed the locktype to pessimistic (and the other options) - still no go...

Any help will be appreciated!

BTW the provider I use (IBProvider) is freeware - the commercial one is $150... I looked in the help/readme but couldnt find anything that states the with the Free version you cannot update/add/delete... Maybe thats the problem???

Interbase Stored Procedures
I have been trying very hard the past couple of weeks to determine the absolute fastest way to insert new records into an Interbase table via Visual Basic and an OLE DB Provider. What I have been able to research so far is that a stored procedure is by far the fastest way to do this. I am setting up the command object and parameters and then attempting to execute the procedure. What I get is:

SQLCode: -92
IBErrorCode: 335544569
Unsuccessfull execution caused by a system error that precludes successfull execution of subsequent statements
Dynamic SQL Error
Parameter mismatch for procedure LOCALDNC_INSERT

The procedure itself is fully tested on Interbase and works. If it is run by SQL, it also runs fine ("EXECUTE PROCEDURE LOCALDNC_INSERT()").

So I know that the procedure itself is fine, its just the ADO command is unable to process it correctly.

I really need to figure this out. If i cannot execute a store procedure than I am really in trouble since performance is not going to meet the project demands at all. Any help is greatly appreciated!

The code i am using is:

Code:
Dim tmpRec As ADODB.Recordset
Dim tmpCom As ADODB.Command
Dim tmpCon As ADODB.Connection
Dim i As Integer
Dim tPhone As Double
Dim tState As String
Dim tFileName As String
Dim tCDate As String
Dim rCount As Long
Dim tCount As Long
Dim tmpStr As String

rCount = 0
tCount = 0

Set tmpCon = New ADODB.Connection


tmpCon.ConnectionString = CurrentProject.Connection.ConnectionString
tmpCon.Open

Set tmpRec = New ADODB.Recordset
If tmpRec.State <> adStateClosed Then tmpRec.Close
tmpRec.Open "SELECT * FROM DNC", tmpCon.ConnectionString, adOpenForwardOnly, adLockReadOnly

If tmpCon.State <> adStateClosed Then tmpCon.Close
tmpCon.ConnectionString = "Provider=SIBPROvider.2;Password=********;Data Source=xxx.xxx.xxx.xxx:E:xxxxxxxxxxxx.GDB;Persist Security Info=True"
tmpCon.Open
Set tmpCom = New ADODB.Command
tmpCom.ActiveConnection = tmpCon.ConnectionString
tmpCom.CommandType = adCmdStoredProc
tmpCom.CommandText = "LOCALDNC_INSERT"
tmpCom.Prepared = True

Do While Not tmpRec.EOF
tPhone = tmpRec.Fields("PHONE").Value
tState = tmpRec.Fields("STATE").Value
tFileName = tmpRec.Fields("FILENAME").Value
tCDate = Format$(tmpRec.Fields("CDATE").Value, "MM/DD/YYYY")
tmpCom.Parameters("PHONE").Value = tPhone
tmpCom.Parameters("ST").Value = tState
tmpCom.Parameters("FILENAME").Value = tFileName
tmpCom.Parameters("CDATE").Value = tCDate
tmpCom.Parameters("DURATION").Value = "6"
For i = 1 To 7
If tmpRec.Fields("DNC" & CStr(i)).Value = "" Then
Exit For
Else
tmpCom.Parameters("FLAG").Value = tmpRec.Fields("DNC" & CStr(i)).Value
tmpCom.Execute , , adExecuteNoRecords + adCmdStoredProc
tCount = tCount + 1
End If
Next i
tmpRec.MoveNext
rCount = rCount + 1
If rCount Mod 100 = 0 Then
Me.Caption = rCount & " Records Processed : " & tCount & " Transactions Processed"
Me.Refresh
End If
Loop

tmpCon.Close

Set tmpRec = Nothing
Set tmpCom = Nothing
Set tmpCon = Nothing

Visual Basic + Interbase : Addnew Error
I am using Visual Basic to connect to Interbase. The connection worked but when I try adding a new record
the following error occurs :

    Runtime Error '3251':
    Object or provider is not capable of performing requested operation.

This is the Visual Basic code I'm using

'Setting & opening the connection

Dim adoConn As New ADODB.Connection

 Set adoConn = New ADODB.Connection
 adoConn.ConnectionString = "provider=IbOLEdb.1;data     source=localhost:C:Program FilesBorlandInterBase
IB_TutorialTutorial.gdb;ctype=win1251;user id=SYSDBA;password=masterkey"
 adoConn.Open

Private Sub TEST()
Dim RS As New ADODB.Recordset, SqlStr as string
 
  SqlStr = "SELECT * FROM Country"
  RS.CursorLocation = adUseClient
  Set RS = New ADODB.Recordset
  RS.Open SqlStr, adoConn, adOpenStatic,
adLockBatchOptimistic
 
  With RS
    .AddNew  ****** ERROR **********
    ![country] = "Malta"
    ![Currency] = "Lm"
    .Update
    .Close
  End With
    Set RS = nothing
 End Sub

I would appreciate any help !!

Thanks



OLEDB/ADO/Interbase Problems With Visual Basic 6.
Anyone here who can explain me how to successfully use Interbase with IBOLEDB (www.oledb.net) in Visual Basic/ADO environment?

I can read records, but when I try to edit them I always get:
"insufficient base table information for updating and refreshing"

I think the problem is maybe in automatic assignment of primary key... but.. that should be only in the case of adding, I get this error on update too..

And some people said I should use db.CursorLocation = adUseClient
why is that? ... too much questions, ... )

pyc

VB6 &amp; Fox Pro Database - How To See Database Structure And Connect W/VB6
I have what seems to me like a big problem.
I have a CD with a Visual Fox Pro Database on it with a one form interface that comes with it that seems to be written in visual fox pro.
I need to create a one form interface to the Fox Pro Database to search it using VB6.

I dont know what the database structure is exactly though.
I can open tables in Visual Fox Pro and see what they contain but not sure of the relationships.
There are multiple files listed at the bottom of this post.

I was wondering if there was a way to connect to this type of database in VB6 and also what that code might look like/an example.
Also is there a way to see what relationships the database has in it; or is that designated by the program itself at design time/in the programs code.

Also what would an interface like this cost to have built. (in case I cant do it myself)
I have an ftp site with the CD copied to it if you need to look at the structure itself or the contents of the database.

Thanks for any help or code that you can provide

Database structure looks like this
Code:
[2004.dat]
    [C]
        DESCRIPT.CDX
        DESCRIPT.DBF
        DESCRIPT.FPT
        INDEX.CDX
        INDEX.DBF
        OP_NUMS.CDX
        OP_NUMS.DBF
        OP_NUMS.FPT
        PARTS.CDX
        PARTS.DBF
        TIMES.CDX
        TIMES.DBF
        VEHICLES.CDX
        VEHICLES.DBF
        VEHICLES.FPT
    [H]
        DESCRIPT.CDX
        DESCRIPT.DBF
        DESCRIPT.FPT
        INDEX.CDX
        INDEX.DBF
        OP_NUMS.CDX
        OP_NUMS.DBF
        OP_NUMS.FPT
        PARTS.CDX
        PARTS.DBF
        TIMES.CDX
        TIMES.DBF
        VEHICLES.CDX
        VEHICLES.DBF
        VEHICLES.FPT
    [L]
        DESCRIPT.CDX
        DESCRIPT.DBF
        DESCRIPT.FPT
        INDEX.CDX
        INDEX.DBF
        OP_NUMS.CDX
        OP_NUMS.DBF
        OP_NUMS.FPT
        PARTS.CDX
        PARTS.DBF
        TIMES.CDX
        TIMES.DBF
        VEHICLES.CDX
        VEHICLES.DBF
        VEHICLES.FPT
[2003.DAT]
    [C]
    [H]
    [L]
        ETC down to 1991.DAT directory    

Connect To Database.
I 've completed a program and using InstallShield to make setup file.
When using this file to set up on various PCs. On some it works well, but on some it can not connect to the database (Access).
Does anyone know when this happens? (The path of this database file is OK.)
Thanks for you help!

Best regards,
Carnation

No Database Connect Yet
Hi agn, Well removed all references to the "C" drive from my app
during design time.
I get NO errors during compile BUT installing to any drive A/C I have
no "mdb" no errors but still no "mdb" another but, my hlp are
up and running.
No way to test yet with my "beta tester" on results of "G" drive
Installation success. ........looks like I can't hope for much.

Just for info.
The only reference I had left was "DATA!/PPRPERTIES/NAME
and I deleted that.
Please suggestions.
Tnx
Ray

Connect To Database
hi
i was wondering if anyone can tell me of any simple projects that can connect to my websites database?im using MySQL - 4.0.27-standard phpmyadmin what im trying to do is to get my project im working on to use the username and passwords from my websites database thanks...

I Want To Connect To My Database Over Wan
hi
i'm using vb6 , i want to connect to my database over the wan , and i'm using access 97 .
i just want the code that do the connection to the server on the WAN, i know how to connect to the database in the LAN, but on WAN i don't Know , please help.
thanxxxx very much.

How Can I Connect My Database
hi friends i have a connection problem when i insatall my project

Dim fobj As Scripting.FileSystemObject
Set fobj = New FileSystemObject


If Mid(Dir1.Path, Len(Dir1.Path)) = "" Then
fobj.CopyFile "d:ackuptool est.mdb", Dir1.Path + "" + "test.mdb"
Else

fobj.CopyFile "d:ackuptool est.mdb", Dir1.Path + "" + "test.mdb"

End If
MsgBox "Backup Complete.", vbInformation



so when the drive changes to C: my project does not work


so I want to use this code but it does not work what is the problem

fobj.CopyFile "" & App.Path & " est.mdb"""



my second question is this:
without using a common dialog.

how can i fill my text1 like this:
form1_load
text1.text= "" & App.Path & " est.mdb""
end sub

Connect To Dbf Database
Hi. I'm trying to connect to a foxpro database in visual basic using dao...could someone send some code my way? Thanks

David

How To Connect To An Database
i want to connect to my database using the ADODB connection. plz help

Trying To Connect To Database.
VB Code:
Dim AdoConn as New Adodb.ConnectionAdConn.Open


In the book I'm reading regarding visual basic 6 mastering, it says you need to connect through ODBC but is there a way to connect through any other easy way because I can't find out the correct way

Regards,
Muhammad Haris

How To Connect To A Database ...
Hi.. everyones.

How i can connect to five pcs to other wich have a database mdb files ...

I have a Pc with W2000 not server.. and 5 pcs somes with w98 and others WinXP.
In a WIn2000 pc (ip 173.25.30.65), i have a 4 database mdb files, I need conect 5 pcs to WIN2000 pc using VB6.
How i can do that..??

Groval.

Connect To Database
Does anybody know the proper syntax to open an access database and update a recordset? I'm trying to keep it as simple as possible.

Connect To A Database
There are many ways to connect to a SQL database. What is the difference between using the connection strings with drivers and providers? Which one is recommended?

Thanks

Connect To Database
Hi All,

I have the following Sub.

Public Sub Data_Connect(sql)
'Create Connection to database
Dim ad As ADODB.Connection
Set ad = New ADODB.Connection
Let ad.ConnectionString = "DSN=testing;User Id=;PASSWORD=;Description=testing;SERVER=admin3;UID=;DATABASE=testing"
ad.Open
End Sub

Which I call from a seperate form.

I use the following code.

ad.execute(sql)

to execute a SQL statement and I get the following error

"Variable not defined" on the ad?

Why is it doing this, is there a better way to do this.

Thanks,
Gavin

Connect Database
Hi

How can I connect a MDB database hosted in my web-site from my local
machine?

Thanks, Alviro

How To Connect To Database
good afternoon,

i am trying to make my first asp application.
my problem is : how do we declare the connection to our database in ASP.

thanks,
anna

Connect To Web Database From VB6?
Problem : I am developing software using VB6 which will run
locally on a PC. The database however will be on the web. When
I try to create an ODBC connection it will only look for a local
database.

Is there an ODBC driver I can download which will allow me to


connect to a web database? Perhaps something similiar to the
MySQL ODBC driver - that allows you to specify the server.

Or does anyone know of a connection string I can use which


would do the same?

Thanks,

Mike

VB To Connect To Database
I am writing a program that access a database, I have many function using
the connection string, I would like to centralize my connection in Class so
all my app can access the same connection. What is the best solution to
code this?
Keep in mind that for each connection I am calling different table or
preformed different action. i.e select, update, delete and so on.

Connect To A Database On The Web
Hi All,

I have a Sales Manager who uses this system (VB6 and Access) that I've developed (which runs on a network, Database is on a server and VB6 connects to it). This Sales Manager travels alot, he wants to be able to use this system when he is in a hotel room away from the office, we don't have vpn or anything. so what I was thinking was to have a synchronized database on the web, and on the LOGIN screen of the system it would ask if he is traveling or in office and would connect to the appropriate database. I use DAO 3.6

I've tried to give the address of the database which is on the web in my connection string but that doesn't work.

I would appreciate all the help.

Thanx

Kinara

Connect To A Jet 3.51 Database
I am trying to connect to a Jet 3.51 database.

In a simple form created in VB6,I have added an ADODB object.

In the properties I have selected Use Connection String.

Further I have given my DB name and User name as Admin & myPassword.

When I test the connection,I get following error message:


"Test connection failed because of an error in initializing provider.

Cannot start your application .The workgroup information file is missing or

opened exclusively by another user."

Case 2:

The connection is successful if I connect to a database without password.

My Connection String is:
conAcc.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;Data Source= & AppPath & DataAcc.mdb"

if I change Connection String to below:
conAcc.ConnectionString = "Provider=Microsoft.Jet.OLEDB.3.51;Data Source= & AppPath & DataAcc.mdb;Jet OLEDBatabase Password= "123""
I received Error mesage:
Couldn't Find Installable ISAM
My Vb is VB6
My Access is Access 97

Thanks in advanse

How To Connect Vb To Database If...
Hi,

I need help with how do I connect visual basic to the database if I have database and vb code in the different folder? For example, if I have a folder called MyJournal and I have a sub folders in there like Forms, Modules, and Database. How can I connect to my database then? I know if I put in the same folder, I will be able to connect it, but if I put in the different folder, I can't.

Thank you for your time.

Connect To Database
I am writing an application which uses MS Access DB and I am going to switch to a MS SQL server. What is the best way to connect to the database ODBC connection or refference the database in my code?

How 2 Connect Into Database On The Web ?
})&gt;+- Please help -+&lt;({

I have an Access database "datafile.mdb" on my web-site that I want to get connected to,
it is working fine when I run it from my web-site using vbscript:

Connection.Open = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=d:htmlwebsiteDataBasedatafile.mdb;Persist

Security Info=true"



Question:
~~~~~~~~~
how can I connect from a VB application on my desktop
into the database on the web-site ?

can I use the ADO object for this too ?

can I give my Connection some kind of "Base"
like: http://www.mypage.com
so it will think it is connecting like it was an ASP page ?

10X


··(Tip): 2 get code from this page - first paste it in2 FrontPage and then in2 NotePad...
··
··Best Regards - Yovav Gad
··EMail: Development@SuperMain.com
··Web-Site: http://www.SuperMain.com

Connect Database (SQL) To Vb ????
Is it possible to connect a database to VB without using ADO or ADODC , just codes.....?

thanks in advance.

DonRafouk

How To Connect To Sql Database Thru DSN
i have made a system/file dsn for sql database
and want to create connecion to database thru DSN.

Please help ASAP.

regards

How To Connect To Sql Database Thru DSN
i have made a system/file dsn for sql database
and want to create connection to database thru DSN.

Please help ASAP.

regards

Vba In Ms Word For Mac --- Connect To A Database??
Hello there,

Ik have run in to a little bit of a problem. A friend of mine has a apple system with Ms Word for mac. I want to put information from database into a vba form in word, for example filemaker pro database.

I have tried to use the mailmerge element but i can't find the object to readout the datasource in my vba form.

I looked at odbc, but i can't find how to use that in ms word.

If you have a suggestion i really want to hear about it!

Thanx for your time.

How To Connect SQL Server Database In VB
I creat a Database GSM in SQL Server 7.0,but I can't open it in VB.
for example:
Conn = "UID = admin;PWD = 1234;DATABASE = GSM;" & "SERVER=PDCOFMTL;DRIVER={SQL Server}"
Set myEn = rdoEngine.rdoEnvironments(0)
Set myCon = myEn.OpenConnection("", rdDriverNoPrompt, False, Conn)
It always reportata Source Name not fount and no default driver specified.
Why ?

HOWTO: Connect VB+DATABASE Within A LAN
Hi!

This may sound stupid for you guys, but it goes something like this..

I have these vb and database on a PC.. the problem is the connection of each PC in the network..

How can I connect the program embedded in the server so that the client can access it? Is there something to do with the connection string or what??
To make it simple, how will I configure the connection??

Please help.

Thanks.

Connect To Sql Server Database
I'v been programming in Access for a while now, but I have a project now that requires me to use MS Sql Server and vb6.

the sqlserver is on the same drive as the vb appication. How do I connect to the sql database.

Connect Foxpro Database
i made a program using an access database.

But i have an older program using a foxpro database.

i want to migrate same tables from the foxpro database to my access database. how can i do that ?

i dont know how the foxpro tables were created. i just know where the database is. "c:ourodatabase"

From, emidio braga

Connect To Database With Inifile
HI

I am traing to do 2 things

connect to database with ini file ?

and the main exefile I am traing to make exe file to call the main exe from ini file then I can make upgrade in the ini file and the user only need to restart the program when I comolen new ver and change the mane in ini file from ver 1.1.1.exe to ver 1.1.2.exe

How can I do this with can somone show me link or how ? I can make this work

[PATH]

PATH=\micealgagnaskradb1.mdb

[MAIN]
FILE = ver 1.1.1.exe

strPath = "\micealgagnaskradb1.mdb"

Connect To Mysql Database?
I am trying to connect to mysql database from VB6
I have installed drivers etc...
Setup is on jpg file and error also

Any ideas on connection error??

Any help appreciated...


cnn1.ConnectionString = "driver={MySQL};" & _
"server=http://r112.easily.co.uk:85/;uid=webmaster;pwd=secret;" & _
"OPTION=3"

Connect To A Network Database....
how do i gotto connect to a network computer that having a database?.....or is it possible to write a program that can retrieve and update the database from a host computer?

How To Connect To An Access Database?
Hi

I have an access database (.mdb) and i'm trying to connect at it, haven't found a way to make it work

Does anyone know how to connect to an access database, how to get record and how to insert a record? (I know SQL language so you don't need to explain it =) I only need to know how to connect and create recorsets etc...)

Thanks alot

Connect To Mysql Database
hello everyone,
i have a mysql database on a free hosting site. this is www.tripod.lycos.co.uk. it has just one table in it. i want to know if it is possible to connect to this database and then retrieve data from the table using visual basic.

i want to populate a list box with the data in the table.

can anyone help.

thanks a lot

Connect To Sql Server Database
Does anyone know how to connect to an sql sever database that has a password and username on it.

thanks

Copyright © 2005-08 www.BigResource.com, All rights reserved