Compact MC Access Database with labview
Hello,
How do I compact an MS Access programatically from labview to reduce its ballooning size? I have the database connectivity toolkit.
Thanks,
Ron
What datatypes are you storing? Using the wrong datatype can cause all kinds of size problems--as in the datafile expanding at a rate several times the size of the data you're putting in it...
Mike...
PS: If you are running Windows you have everything that you need. Access is not actually a database package. It's an application development package for creating programs using Jet. Jet is the DBMS that Access uses, and Jet is installed by default with Windows.
Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion
"... after all, He's not a tame lion..."
Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps
Similar Messages
-
Does anyone know how to compact an Access Database programmatically from LabVIEW?
Can the Database Connectivity Toolset be used?I have created a LabVIEW solution for the MS Access DB compressing issues we have all seen.
I am actually using the MS Access Compress and Repair function via
Active X. There are ways to also use the Jet Engine to call the same
function, but I could not get it to work using a required DB Password
to be entered. The code uses the Database Toolkit from NI so I hope all
of you have that. It also uses MS Access 2000 active X component. It
should work for any version of Access, but it needs to be recompiled
for different versions of Access. let me know if it works out for any
of you.
The code allows to use a temp folder to create the compressed DB, or to
put it in a backup folder of your choice. It also handles replacing the
original database with the compressed one. The code finds the database
given the connection reference being passed in. I use the ADO
connection string to find the database location and the File DSN in
order to reconnect to the database. I built it for my specific needs
but I am sure any of you can customize it to your needs as well.
Thanks,
--Kevin
Kevin Shirey
PVI Systems Inc.
Certified LabVIEW Developer
Attachments:
Compact DB Via DB Conn Ref.vi 133 KB -
How can I compact a MSAccess database with java?
Hi.
I have a question (Please Help!!!):
How can I compact a MSAccess database with java-jdbc? Is it posible?
ThanksMS Access database has a max length limitation of 2.14GB for Access 2000( 1.07G for Access 97), and won't recycle basically space for update/delete sql so tha it's a good idea to use MS Access database for program, which need update/delete frequent ly data. The programmers of HXTT Access(www.hxtt.net) are writing code for CREATE TABLE/DATABASE sql now. If you need a pure Java solution for PACK TABLE/DATABSE urgently in your project, you should send such a requirement to the Support page of www.hxtt.net so that they can schedule complementing such a fucntion. Otherwise, you should pack your databae manually or visit C++ code for Compact an Access Database Programmatically at
http://www.codeguru.com/Cpp/data/mfc_database/microsoftaccess/article.php/c4327/ , or use Easy Microsoft Access MDB MDE Compactor at http://www.easyhr.com.au/software/easy_mdb_mde_compactor.htm. -
Connecting MS-Access database with Oracle Forms
Hai,
Can any one suggest as to how I can connect MS-Access database
with Oracle Developer Forms. What is the procedure ? Suggest me
if I need to install any drivers. Waiting for an early reply.
Warm Regards,
Raghav.
email:[email protected]Not possible as far as I know.
Probably because ODBC itself (the defined interface) doesn't support it.
There is a commercial MS Access (java only) driver that might support it. -
How to compact and repair a MS Access database with NI CVI 8.5 (and SQL Toolkit)
Hello
I'm using the SQL Toolkit with CVI 8.5 for accessing MS Access Databases.
Is there a possibility to compact and repair the .mdb file with CVI?
Thanks in advance.Hello Ulrich,
with compact and repair I mean the MSAccess function "Compact and Repair".
Please follow the link below for more details:
http://office.microsoft.com/en-us/access-help/compact-and-repair-an-access-file-HP005187449.aspx
Normally you can execute this function directly in Access or with the Windows ODBC Data Sources Administrator => "Control Panel" => "Administrative Tools" => "Data Sources (ODBC)"...
I want to execute this function via cvi code and not by hand ;-).
Thank you for your support.
Frank -
Transferring a lot of data from Access Database to Labview
I need to transfer 500000 -> 1000000 values in a Access database table to Labview. The values are selected using a query which is very fast if run in Access itself, but from Labview it's very slow. Obviously the connection between Labview and Access is the slow point.
Im using the NI Database connectivity toolset and a UDL file defines the connection. Microsoft Jet 4.0 OLE DB Provider is used.
To be honest i dont know what that really means, just that it normally works but now its stupidly slow for so much data.
Thanks for any help.
RobOne of my continual gripes with the DBCT is it's poor behavior on large data sets. See NI's response here:
http://digital.ni.com/public.nsf/3efedde4322fef19862567740067f3cc/862567530005f0a186256a33006b917a?OpenDocument
Actually, I wouldn't find it nearly so annoying but for the part that says "In most database books you are told not to return large recordsets...". I prefer the freedom to make a mess of things myself, thanks.
On the plus side, the VI referenced in the article is fairly efficient, you just have to deal with type conversion once things have been moved into LabVIEW. -
Size limit of access database with image files stored outside database
I have read 2GB limit on size of Access database. We are using Access 2013 database with fields that are data type attachment and storing attached images outside the database. Does the size of the folder that is holding these images count
in any way toward 2GB size limit?Hi,
As far as I know, Access database limit size 2GB based on itself, not related to the folder size. Attachment data
type is similar to attaching files to e-mail messages. We need to control the Access database size is smaller then 2GB.
When a field is defined with the attachment data type, you can store one or more files for each record in it.
Attachments can dramatically increase the size of the database, but since the attached file is stored as a part of the dabatbase, you are not dependent on network drives being available as you would be if you inculded a hyperlink to the file. As a matter of
fact, feel free to backup the origainal file to other disk after you attach it to the database.
Regards,
George Zhao
TechNet Community Support -
How to connect with Microsoft Access Database with JAVA
I want to know the command and query to connect between MSAccess and JDBC.
Is it beter way to make connection with MSAccess comparing with other Databases such as SQL and Oracle.
Which Database will be the best with Java?
I also want to know to be platform indepadent which database is suitable?On Windows, you can use MS Access database by:
Set up a System Data Source using the ODBC control panel applet.
Use the jdbc:odbc bridge JDBC driver, and specify a jdbc url that points to the data source name you just specified.
It's been too long since I've done this, so I don't remember the syntax of the jdbc url, but I'm sure that if you do a search for the jdbc:odbc bridge that you will find what you are looking for.
As far as the question about which database is best, you will need to determine that based on your project requirements.
If you want a quick and dirty, open source, cross-platform database, take a look at HyperSonic SQL.
- K -
Please help, cannot connect to Access database with a jar file
Hi, i created a jar file from my java project, using eclipse.
When i try open the jar through command prompt, the following error is given:
java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Could not find
file '(unknown)'.
at sun.jdbc.odbc.JdbcOdbc.createSQLException(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.standardError(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.SQLDriverConnect(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcConnection.initialize(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcDriver.connect(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at Methods.con(Methods.java:15)
at LoginScreen.getCmboLogins(LoginScreen.java:80)
at LoginScreen.getJContentPane(LoginScreen.java:65)
at LoginScreen.initialize(LoginScreen.java:46)
at LoginScreen.<init>(LoginScreen.java:31)
at DataUse.main(DataUse.java:25)
No Connection to dataBASE
The program runs fine within eclipse and the database is bundled in the jar.rohangr wrote:
The program runs fine within eclipse Because the database isn't in the jar.
...and the database is bundled in the jar.That isn't going to work.
The MS ODBC driver (which has absolutely nothing to do with java) expects to find the MS Access file in the windows file system.
And the contents of the jar file does not fit into that requirement. -
How compact a mdb (Access 2k) with LabSQL?
How compact a mdb (Access 2k) with LabSQL?
I believe that you are asking "how to compact an Access Database programmatically from LabVIEW?" If so, you may want to consult :this discussion forum which concerns the same questions.
J.R. Allen -
Hi there,
I was wondering if i could link a access database to labview.
I could do with linking field as well as writing/deleting etc.
And if I could sort as well that would really be good!!!
Thanks again everyone!!!Hello Peter, You can also use the Database Connectivity toolkit for LV. Have a look at the information on NI's website. This may make life easier!
You may also be able to do this programmatically using MSQuery in Excel or Access and you can control these products using LV. This would be rather challenging though.
The suggestion made I think is also possible.
Hope this helps
Kind Regards
Steven Bird
Applications Engineer
National Instruments -
Java ODBC image database with MS Access
hi ,
Can any one please tell me if it is possible to put and get image from MS Access database with java JDBC ODBC driver? If it is possible then what will be the data type in Access and java. Thanks in advance ��I've not seen a data type in Access that would be
appropriate for iimages--and I believe Access may
still have an overall size limitation (this may have
been taken off in Access 2003). If this were Oracle, you'd be using a BLOB. But the reasoning that follows would be the same, regardless of database.
What I'e had best
luck doing is leaving the files in their native
format and storing them in directory structures to
keep them segregated if need be, and storing their
names and locations in the DB.This is what I've seen done. It makes little sense to stick the JPEG bytes in the database. You can't use them in a WHERE clause. They just kill database performance. morgalr's solution is a good one.
% -
[JDBC][ODBC] How to compact access database from Java ?
Hello,
I'm developping a java applcation wich is connected to an MS Access file database.
For now, I don'y compact it but it would be better.
So How can I compact an access database from Java ?
thanks :)Hi ypiel,
Try this:
1) Download JETCOMP.exe (freeware from Microsoft);
2) Put the following code in your app (assuming your database file name is: "DB.mdb"):
try {
File current = new File("DB.mdb");
File backup = new File("BACKUP.mdb");
if (current.renameTo(backup)) {
Runtime.getRuntime().exec("jetcomp -src:BACKUP.mdb -dest:DB.mdb");
} catch (Exception e) {
System.out.println(e.getMessage());
Best regards,
YT. -
Hi,
I want to write a application that uses an Access Database. Actually I want to write data to and read data from a Database with Labview. Does anyone knows a library to control a Access Database. Or any other solutions.
DavyYou've got several options. There is a shipping example that uses DDE to talk to an Access database. DDE sucks so you probably don't want to do that. There is ActiveX. There have been a lot of examples posted to the forum so you might want to do a search. ActiveX can be a real pain though. The nicest solution is to buy the Database Connectivity Toolkit from NI. It uses ADO/SQL to communicate to any database and hides a lot of complexity of learning SQL. There is also the free open source toolkit called LabSQL from Jeffrey Travis. This uses ADO/SQL to talk to any database. You'll need to learn SQL but that's not really that big a task.
-
UPDATE VALUE IN ACCESS DATABASE-CONNECTIVITY DATABASE?
Hi to all labviewers,
I'm trying to update some values in my access database with sql and labview connectivity toolset but i got
an error, what is the problem whit my code?
note: when i try to update one colum it's work fine.
regard's
eyal.
Attachments:
UPDATE_ACCESS.JPG 79 KBHi,
I'm not sure if you can use comma's to seperate criteria. Thy this:
WHERE criteriuma='something' AND criteriumb='something else'
Regards,
Wiebe.
"Discussion Forums" <[email protected]> wrote in message news:[email protected]..
Hi to all labviewers,
I'm trying to update some values in my access database with sql and labview connectivity toolset but i got
an error, what is the problem whit my code?
note: when i try to update one colum it's work fine.
regard's
eyal.
UPDATE_ACCESS.JPG:
http://forums.ni.com/attachments/ni/170/152737/1/UPDATE_ACCESS.JPG
Maybe you are looking for
-
Extended Desktop - Assigning Spaces
Is it possible to make a second display it's own 'space' when using an extended desktop? I recently started using a second monitor when I am at home, and I'd like to set it up so that certain applications always open up on the extended desktop. Any i
-
Time issue iwhile scheduling meeting in meeting place 8.0
Dear Team, I am very new to Meeting Place system. Here we have version 8.0 and i am facing below issue. While scheduling meeting when i have mentioned start time as 13.30 and end after 30 min. but the issue is user can join the meeting before 13.30
-
How do I get the TC on my Airport Extreme to do wireless backups?
I just want to use the TC for wireless backup. I've connected it to the Airport with Ethernet; unconnected the EThernet; opened Airport Utility; read the Manual; studied all these posts. Nada. It should be simple, I only need the TC to act like a
-
Open iweb website in other program?
Hallo guys, I've been using iweb and now I just bought a new macbook pro and iweb isn't there anymore. 1) I heard downloading isn't possible; 2) I've tried to install from my old disk, from my macbook white 09, but it wouldn't allow me to install. 3)
-
How to open multiple report windows on button click without losing session?
Hi, JDev : 11.1.1.2.0 I am trying to open multiple discoverer plus report windows using my ADF application. My requirement is that user has to select multiple reports from the screen and by clicking on submit button all the reports should be opened i