Ferret File System/v0.1/SQL/file: Difference between revisions

From Woozle Writes Code
Jump to navigation Jump to search
(minor updates, format tidying)
(moved most fields to dirent)
Line 1: Line 1:
==About==
==About==
* '''Purpose''': Tracks actual locations of files, and stats which may be different from file to file without affecting the data/content.
* '''Purpose''': Tracks actual locations of files, and stats which may be different from file to file without affecting the data/content.
===fields===
===history===
* '''2016-02-27''' Moved many fields to {{l/same|dirent}} and replaced them with '''ID_Entry'''.
==SQL==
==SQL==
<mysql>CREATE TABLE `files` (
<mysql>CREATE TABLE `files` (
   `ID`         INT          NOT NULL AUTO_INCREMENT,
   `ID_Entry`   INT          NOT NULL AUTO_INCREMENT,
  `ID_Folder`  INT          NOT NULL COMMENT "Folders.ID of parent folder",
   `ID_Firev`    INT DEFAULT      NULL COMMENT "Firevs.ID for this file",
   `ID_Firev`    INT DEFAULT      NULL COMMENT "Firevs.ID for this file",
   `FileName`    VARCHAR(255)          COMMENT "just the filename.ext, not the full path",
   UNIQUE KEY(`ID_Entry`)
  `WhenCreated` DATETIME DEFAULT NULL COMMENT "file's creation timestamp",
  `WhenChanged` DATETIME DEFAULT NULL COMMENT "file's modification timestamp",
  `FirstFound`  DATETIME    NOT NULL COMMENT "time/date when file was first found during a scan",
  `LastFound`  DATETIME    NOT NULL COMMENT "time/date when file was most recently found during a scan",
  `isFound`    BOOL DEFAULT FALSE    COMMENT "TRUE = was found on most recent scan",
  PRIMARY KEY(`ID`)
)
)
ENGINE = MYISAM;</mysql>
ENGINE = INNODB;</mysql>

Revision as of 17:20, 27 February 2016

About

  • Purpose: Tracks actual locations of files, and stats which may be different from file to file without affecting the data/content.

fields

history

  • 2016-02-27 Moved many fields to dirent and replaced them with ID_Entry.

SQL

<mysql>CREATE TABLE `files` (

 `ID_Entry`    INT          NOT NULL AUTO_INCREMENT,
 `ID_Firev`    INT DEFAULT      NULL COMMENT "Firevs.ID for this file",
 UNIQUE KEY(`ID_Entry`)

) ENGINE = INNODB;</mysql>