001_InventoryStore.sql 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. create table InventoryFolders (
  2. ID NVARCHAR(255) not null,
  3. Type SMALLINT null,
  4. Version INT null,
  5. ParentID NVARCHAR(255) null,
  6. Owner NVARCHAR(255) null,
  7. Name NVARCHAR(64) null,
  8. primary key (ID)
  9. )
  10. create table InventoryItems (
  11. ID NVARCHAR(255) not null,
  12. InvType INT null,
  13. AssetType INT null,
  14. AssetID NVARCHAR(255) null,
  15. Folder NVARCHAR(255) null,
  16. Owner NVARCHAR(255) null,
  17. Creator NVARCHAR(255) null,
  18. Name NVARCHAR(64) null,
  19. Description NVARCHAR(64) null,
  20. NextPermissions INT null,
  21. CurrentPermissions INT null,
  22. BasePermissions INT null,
  23. EveryOnePermissions INT null,
  24. GroupID NVARCHAR(255) null,
  25. GroupOwned BIT null,
  26. SalePrice INT null,
  27. SaleType TINYINT null,
  28. Flags INT null,
  29. CreationDate INT null,
  30. primary key (ID)
  31. )
  32. create index item_group_id on InventoryItems (GroupID)
  33. create index item_folder_id on InventoryItems (Folder)
  34. create index item_owner_id on InventoryItems (Owner)
  35. create index folder_owner_id on InventoryFolders (Owner)
  36. create index folder_parent_id on InventoryFolders (ParentID)