MS ACCESS read binary file - metadata

  • Thread starter Thread starter guruisf
  • Start date Start date
G

guruisf

Guest
I want to open the MS ACCESS databse in binary format and extract

1- MS ACCESS version
2- Number of tables in it
3- Number of columns in each table
4- Type of each field
5- NULL/NOT NULL status if each table field
6- Unique number

I don't want to use any ODBC connection or any object, just wanted to read
binary file and create the metadata of MS ACESS database.

Kind Regards,
Irfan
 
Ms Access 97

I want to open the MS ACCESS 97 file through my command line utitlity and analyze all its structures.
 
You want to reverse-engineer your Access binary database.

If you have a copy of Access on your machine, this proposed action is a direct violation of your Access license agreement that you clicked "YES" on when you installed Access in the first place. Go read the license agreement again before trying this at home or especially at work.

If you work for any branch of government (National, state, local) and do this, you can actually jeopardize all of your organization's licenses in a single action whether you do or don't have Access on your machine, particularly if a site license is involved. This kind of thing is how people get fired from government offices. Can't speak for your locale, but in Louisiana, it is a felony with a $5,000 fine and up to 5 years in the pokey to illegally analyze a file in violation of a licensing agreement covering that file.

Even if you don't have an Access license, MS has all sorts of stuff hidden in the file that will make it illegal to reverse engineer. Like, embedded copyright notices and the like. Don't do this and make it public. MS prosecutes to the hilt if you publish.

OK, now that we've got the legalities out of the way...

I can't legally post how to do this in binary, either. But I can tell you some things about how to get parts of this in other ways. And I'm not kidding ... legally, these are the only ways you can get to this sort of thing without a license violation. I'm not about to give you info that could lead to felony prosecution. Particularly if I could end up as an accessory before the fact. In the USA, that's called a co-conspirator, and as much as I dislike Bill Gates and Friends, I'm not about to drop my pants and expose myself to that kind of hose job.

These are the LEGAL ways to find out about what you just requested:

1- MS ACCESS version

Open the database with Access. Your copy of Access will tell you what version of the file it is and might offer to convert it for you.

2- Number of tables in it
3- Number of columns in each table
4- Type of each field


Open the file with Access. In the Tools >> Analyze >> Documenter you can generate such a listing that you can save in .RTF file format.

5- NULL/NOT NULL status if each table field

HOLY GUACAMOLE, you know not what you ask... Access uses a "Sparse" layout scheme. If the field in question is a text field, you MIGHT be able to find this out, but if the field is binary, there is no guarantee that it will be something you can analyze that closely. In a "Sparse" collection, odds are that null fields don't exist at all rather than existing as fields mared 'null'.

To get this, you'd do better to open the file with Access and build queries for this sort of thing. And if you've got a lot of records in the table, this will take forever.

6- Unique number

Like, the license key number of the copy of Access that built the DB? I'm not sure if this is stored in older copies of .MDB files at all. Newer versions, maybe. Heck, WinXP might have some of this stored in the file's associated descriptive data if the DB was created on AcXP under WinXP. Access 2.0 - I doubt it strongly.

Now, the only other way to do this is to approach Microsoft and ask them if they would like someone to develop a data recovery utility that reads the binary of any database for them and extracts information from it.

If they say "Yes" then ask for a contract to do the work and the binary file layout information.

If they say "No" then back away from the table slowly, keeping both hands in plain site as you leave the nearest door. Make no sudden moves. Watch over your shoulder for the rest of your life.
 

Users who are viewing this thread

Back
Top Bottom