• 0

directory structure


Question

I need sum way to get my diectory structure basicaly 4gb of mp3. I need them in a database access preferably so i can do a giu to a director structure.

i need like a table of all the folders

then a table of all the subs

then a table of all the subs of them

then a table with all the files and what folder they are in

cheers

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

Create an Access or SQL database with the following tables:

Directory (1st table)

DirectoryID - should be an auto-incrementing field of numbers (autoNumber in access, int or varchar in SQL Server) to create a unique ID for the directory

ParentDirectoryID - should be the same datatype as DirectoryID, but can be NULL and defaults to 0. Will be assigned the DirectoryID of another directory if it is a sub, will be "0" if it is a top-level directory.

DirecotryName - a string field to hold the name

...any other information about the directory...

Files (2nd table)

FileID - should be an auto-incrementing field of numbers (autoNumber in access, int or varchar in SQL Server) to create a unique ID for the file

DirectoryID - should be the same datatype as DirectoryID from the Directory Table and can't be null since a file has to be in a directory.

FileName - string field for a friendly filename.

FilePath - optional field if you want to specify where the file is (but I recommend a different approach)

...any other information about the file

I would recommend that you name the files with their FileID, so it might be a Barenaked Ladies MP3 file, but it would be named "1001023.mp3" if the corresponding FileID was "1001023" for that Barenaked Ladies song file. Get it? That way you don't need a "FilePath" field, instead you can access them like this, and when you want to change a File's directory, it's only changed in the database, you won't have to change the actual file.

Then create a system, either web-based or Windows-based for the database (or Access-Forms-based for Access) and start inputing the information. Then go back and rename all of your MP3's to their corresponding FileID names. That way the directory GUI will say "BareNaked Ladies - One Week.mp3", but it will actually point to "1001023.mp3" and it will be less of a headache in the future, trust me.

If you would like help on this project, let me know, I'm happy to talk with you about it.

iUk

intentionallyu@msn.com

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.