cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Access from xMII to Dbase(dbf) file

Former Member
0 Likes
646

Hi, EveryOne,

I have a client which stores history data in .dbf file and all of them's file name is more then 10 symbols length.

Does somebody know how to get access to dbf?

Great thnks and best regards,

Serj

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Likes

If you have a DBF file containing a local database table, you first create an ODBC data source in Windows Services:

- Go to (windows) start -> control panel -> administrative tools -> data sources (ODBC)

- Go to tab “system DSN” -> click on “add” -> click on “Microsoft dBase Driver”

- Click on “finish”

- choose “select” in database area

- navigate to the file directory: C:\path-to-dbf\dbf-file-with-more-than-10-chars-in-name.dbf

- choose the database by clicking on it

- and click “ok”

- define the name “FOODBF” for the datasource and confirm by clicking on “ok”

- confirm the datasource creation by once again clicking on “ok”

As a second step, create the ODBC server connection in xMII:

- logon to xMII -> go to “data services” -> “data servers”

- choose “default ODBC database”

- copy this database

- rename it to “FOODBF”

- rename the database description as you like

- rename the server URL to jdbc:odbc:FOODBF

- click on “save” -> click on “status” to see if the database is running

Hope it's clear enough. You can play with FOODBF name if you like.

Cheers.

Former Member
0 Likes

Paul, Hi

Your suggestion works great with files which have a length of 8 simbols or less but not more. it is WinCC 5.1.

I think we have a great difference in time. I will try to find workaround with longname.

Serj

Former Member
0 Likes

Not working. and it's impossible to cut filenames. -(

abesh
Contributor
0 Likes

The best way as Rick mentions is to use the OLEDB UDS.

Download the same from SAP Service Marketplace or click on this link :

<a href="https://smpdl.sap-ag.de/~swdc/012002523100006378582006D/XMIIOLEDBUDS_3-20001994.zip?_ACTION=DL_DIRECT">XMIIOLEDBUDS</a> and try to configure it.

In case you face any problems, post here, and i'll be glad to help

Former Member
0 Likes

Abesh, HI

I want to be wrong but it does not matter OLEDB UDS or just as Paul said in both cases you will see the error:

Error found. OLEDB Error Record #(0x1): [source = Microsoft OLE DB Provider for ODBC Drivers] [error = [Microsoft][ODBC dBase Driver] <b>The Microsoft Jet database engine could not find the object 't_zagotovka'.</b> Make sure the object exists and that you spell its name and the path name correctly.]. Error was spawned by -- File:.\Query.cpp Line:89 Function:COleDbQuery::ExecuteOleDbMode.

But if you cut the file name there is no mistake.

Serj

Former Member
0 Likes

Hi, Everybody,

Everything is working. For history I did:

1. Find Microsoft FoxPro VFP Driver for DBF. Install it

2. It is impossible to configure this driver through ODBC config but it can be done by ..

3. Create OLEDB UDS. Make the connecting string "DRIVER=Microsoft FoxPro VFP Driver (*.dbf); Exclusive=No;SourceType=DBF;SourceDB="+ Path to the directory of file"

4. After it put any configuration data you would like, remember after pressing the button “Finish” you can not change at all anything because of error

Great thnks to everyone,

Serj

Answers (3)

Answers (3)

Former Member
0 Likes

Hi, Sergey.

Actually, you want to use the OLEDB UDS connector and an OLEDB driver for DBF files. This will be your optimal performance, lowest cost, and most reliable solution.

You must be very careful, however, that your OLEDB driver does not lock the DBF files if they are simultaneously being written do by the data storage application.

Generally, apps that would use a DBF format were not well designed for multiuser access.

Best regards,

Rick Bullotta

Former Member
0 Likes

Get an ODBC driver for dBase (google it). Then use the xMII ODBC_Database data server. If there is an available JDBC driver then use that one.

Former Member
0 Likes

Hi Sergey,

What kind of history data they are storing and what kind of database files they are...

Thanks,

Rajesh

Former Member
0 Likes

Hi, Rajesh

1. flowing water

2. water pressure

3. water level

4. others

Serj

Former Member
0 Likes

It is general dbf files