| |
|
If this is your first visit, be sure to check out the FAQ by clicking the link above.
You may have to register before you can post: click the register link above to proceed.
To start viewing messages, select the forum that you want to visit from the selection below.
|
 |

07-22-04, 10:38
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
Btrieve ODBC Driver/Scheduling Exports
|
|
I'm looking for some suggestions on what might be the best way to accomplish what I'm describing below...I'm an ASP web developer looking for a way to regular push some database data to a web server for use in our online applications.
Currently I'm stuck with a commercial software product for our industry that uses Pervasive to write data to flat files mapped with a DDF. (Not ODBC compatible.) I'm looking for a way to regularly export this data to a format I can use on the web server (to a text file or SQL server for example.)
My experience with pervasive and btrieve is pretty limited, so I'm thinking the best way for me to go would be a commercial program that can run on 2k server as a service or desktop engine to perform regularly scheduled exports of our data to a file and then FTP to a server, or go directly into SQL server. I've seen some products that run on top of Crystal Reports to schedule reports, but this seems to be a round-about way of doing it since really all I need is the data itself in a ODBC format. Any suggestions?
|
Last edited by probelaw; 07-26-04 at 12:00.
|

07-22-04, 11:24
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
First, what version of Btrieve/Pervasive are you using? Second, why aren't the DDFs ODBC compatible? Third, why hasn't the vendor of the software package fixed the DDFs?
The thing with Btrieve is that only the application (or DDFs) know the record structure. If you can get an accurate record structure, accurate DDFs can be built an you can use ODBC directly. You could also write a program to export the data in to any format you want. It would need to use the Btrieve API, if the DDFs aren't correct.
You could look at the Pervasive Data Integrator ( http://www.pervasive.com/dataintegrator/). It might help but you'll still need to know the record structure.
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|

07-22-04, 12:24
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
|
|
It's pervasive sql2000i, not sure of the version of btrieve. How could I find this out? I've been told by the software vendor they intentionally don't want the data to be odbc compatible...basically so any data editing goes through their program, which makes sense, but I'd just like to schedule regular dumps of the data so I can use it on the web.
|
|

07-23-04, 15:58
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
The ddfs should be in an appropriate format...I can use crystal reports to read data from them, but how do I go about making a ODBC connection to them?
|
|

07-26-04, 08:01
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
When you use Crystal Reports are you using the Btrieve driver or the ODBC driver? All the DDFs need to do is describe the data files and indexes. If they do that, then you can use ODBC. Have you tried creating an ODBC connection? Does it work? Failing that, can you use the Crystal Report web viewer to view the reports?
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|

07-26-04, 10:28
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
Crystal is using the Btrieve driver. (PDBBTRV.DLL) How do I go about using this driver for an odbc connection? I don't have it in the ODBC control panel.
I can use the web viewer, but really what im trying to do is get away from crystal reports and just use the raw data.
|
|

07-26-04, 13:58
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
You can't use the Crystal Btrieve driver through ODBC. You have to use an ODBC driver.
What happens if you create a Pervasive ODBC connection to the DDFs? Does it work?
You cannot get to the "raw data" without doing one of two things:
1. Write a Btrieve level interface for your web server. This can be CGI or ISAPI or whatever. You will need to know the exact record structure down to the byte.
2. Use ODBC with DDFs that define the indexes, fields, and tables.
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|

07-26-04, 14:21
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
I can't connect with the pervasive odbc connection (i.e. "Driver={Pervasive ODBC Client Interface};ServerName=srvname;dbq=@dbname") becuase my data isn't really stored in a "database" on the server running pervasive. The only database that I can connect to that was is "demodata". It appears as if the software writes diretly to the files.
That being said, there are ddf files that crystal uses to read the data. Is there a odbc driver that I can use with the DDFs and the data files? I'm assuming if crystal can read them the DDFs contain define all the appropriate info.
|
|

07-26-04, 14:38
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
Using that syntax, you will need to create a database name on the server (the machine where the data and Pervasive engine reside). Once you do that, that connection string will work (you don't need the "@" though in the DBQ parameter).
If you create a new Pervasive ODBC Engine Interface DSN, you will have to create a Pervasive DAtabase Name (DBN). The Database Name points to the DDFs/data files. The DSN references the DBN.
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|

07-26-04, 16:07
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
Ok, that makes more sense. Is there any way to go about using the data w/out pervasive?
|
|

07-26-04, 16:24
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
Short Answer: No.
Long Answer: The Pervasive engine is required to read Pervasive files. The internal file structure is proprietary and is not documented. If you were to reverse engineer the file format, you would need to read the bytes and convert it. It would be similar to trying to drive a car without a motor. It's possible but not worth the work.
Have you tried to create a DBN/DSN? If not, do that.
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|

07-27-04, 09:39
|
|
Registered User
|
|
Join Date: Jul 2004
Posts: 44
|
|
I created the DBN/DSN at it works great with the connection string. Thanks for all the info...as I said I've never really worked much with pervasive.
I think what I'm going to do is use a separate server running pervasive that I can push the actual data files to every night or something. This way I'm still keeping my live data separate from my read-only web data, but without any conversion.
Thanks agaiN!
|
|

07-27-04, 10:29
|
|
Registered User
|
|
Join Date: Dec 2001
Posts: 1,026
|
|
You can also set the DSN open mode to Read Only. That way you will only need one engine. To push it out to another server, you will have to have two licenses and two engines running.
__________________
Mirtheil Software
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development
http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
|
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|