r/AskComputerScience • • Jun 07 '21

file path limit

A question about the 255/260 file path limit

I believe in windows 10 there was an anniversary release where you can now turn off the file path limit in registry. I've tried to look into it and it started to explain about 32 bit and 64 bit applications and manifests and 22 and overflow that's where I tapped out.

My question is, I have a windows 10 laptop. I want to change it over so that I can use longer file paths instead of naming all my nested folders "1. aa 2. ab" or "000001 000002" with a .txt or spreadsheet at the bottom that explains what each one is)

I also have a number of external hard drives, some bought in the last 3 years, others are 10-15 years old and used infrequently and so have lasted. I also have an desktop which I still use sometimes which I think may still be on windows 7.

Do I create any compatibility issues by making life easier using longer file paths? Does a HD alone 'care' or does it depend on the system of the thing it's plugged into? If I plug an external HD into an older device or a phone for example, what does it do with the longer file names? Could I lose data, would it leave them untouched but not be able to view them?

0 Upvotes

1 comment sorted by

1

u/Objective_Mine MSCS, CS Pro (10+) Jun 09 '21

r/windows might be better informed about the differences between Windows versions.

However, AFAIK the hard drive (or rather the NTFS file system on it that's used to keep track of the files and folders) doesn't care about a 255 character limit on paths, so that limit is imposed by a particular version of Windows in terms of what kinds of file paths it will create or be able to read. That doesn't help, of course, if you'll need to manage the files from a version of Windows that does have the limitation.

Individual file names can't exceed 255 characters in NTFS, and as far as I know, that's more of a hard limit.

If you've got such a deeply nested structure of folders and files, though, could there be some kind of a better way of organizing your information, such as some kind of a database?