Documents with attachments- use links, tags or groups?

I am just getting into DEVONthink and I have a scenario/case that I am not sure how to store in DEVONthink. In cases where I have a document that has attachments (similar to an email with attachments), how could I store that in DEVONthink?

For example, let’s say I have a Word document “2015-05-10 Financial Report.doc” summarizing my finances that has 2 attachments: Attachment 1 is a chart of finances in the form of an Excel spreadsheet and attachment 2 is a PDF of a bank statement. Also, I have PDF versions of the word and excel files. In OS X folders I would arrange my files using folders as follows:

\Financial Reports\2015-05-10 Financial Report.doc
\Financial Reports\2015-05-10 Financial Report.pdf
\Financial Reports\2015-05-10 Financial Report Attachments\Attachment 1 My Chart 1.xls
\Financial Reports\2015-05-10 Financial Report Attachments\Attachment 1 My Chart 1.pdf
\Financial Reports\2015-05-10 Financial Report Attachments\Attachment 2 2015-01-01 Statement.pdf

Attachment 2 already exists in my database under the group,
\Accounts\Some Bank Acct 12345\2015-01-01 Statement.pdf

Should the Attachment 2 be a replicant or a duplicate?

I think it should be a duplicate as I can rename the duplicate and each duplicate can have unique set of tags. Replicants must have the same name and the same tags.

What name should be given to the folder containing the attachments?

I use the the name of the main document plus a suffix, in this case
“2015-05-10 Financial Report Attachments”

Should the attachment folder be excluded from tagging?

No. This will place folder name as a tag in the attachments. A search can be made to find all attachments using wildcards such as “Attachments”.

Should all the tags in the main document be copied to each of the attachments?

I think Yes. Maybe a script can automate this.

Is there a script that can copy tags from one item to another or all items in a group?

Should there be any links between the main document and the attachments ?

No I dont’ see what can be gained from the effort.

Should the folder containing the attachments be excluded from tagging?

No.

If I replicate the main document should I do anything with he attachments?

I only replicate the main pdf file and don’t replicate the attachments.

There is my methodology, would you please comment on it?

-Mark

Just to confirm – this document has embedded instances of the other documents (except the PDF, of course) – correct?


\Financial Reports\2015-05-10 Financial Report.doc

and, the folder structure is important to maintain in order for the embedded instances to be located correctly by Word – correct?

If so, then I would not import these documents, but I would instead index your file structure.

Here’s why – the hierarchy of groups in DEVONthink is different from where the files are actually stored – in the case where you have imported files into a database, or created them inside the database. This is easy to check – select a document in a group in your database and use Data > Show in Finder to see where the physical document is stored.

For this reason, it is difficult and fragile to embed documents from a database into a Word document. But it is not difficult for DEVONthink to index the folder structure if you keep the files externally from the database.

korm,

Thanks for you reply.

In this case the word documents do not have embedded documents. That would be similar to an email with embedded attachments or a PDF portfolio. If that were the case I could just import the word document and be done with it, however the those attachments would not be searchable.

Also in this case my documents do not have links (relative or absolute) to the attachments. If they did (like HTML documents linking to images or other files in subfolders) I agree its better to index them instead of import to keep the folder structure.

So in this case I need some way to associate a document with its related attachments in an efficient way.

Any suggestions? Is the subgroup a method good?

I am reposting my request. Does anyone has suggestions on handling document attachments in DevonTHINK ? Put them in a subgroup ? How should they be named or tagged?

-Mark

If you want the same document to appear in different groups, use a replicant. If you want to use a document as a starting point for revising something (the content, the name, the tags – something) then use a duplicate. Not enough info provided in your use case to be more definite.

I don’t see a reason to make a separate folder for the attachements, but if you decide you need to do that, then it’s a good idea to have similar names. Groups sort better this way, when you search you’ll see related items in proximity, and it’s just clearer when you glance at the groups looking for something.

I think you have that backwards – excluding a group from tagging will not make that group name into a tag.

There are existing scripts for this (see the Support Assistant) but generally if you select multiple items you can tag them all together by entering the tag into the tag bar.

Not enough info provided in your use case to be more definite. You can always make a table of contents document listing the main document and its attachments. I don’t see much use for that TOC document in this case, but it can be helpful when you want to record a note, or journal, or other factor that applies to the whole set of documents (main + attachments).

Looks like the same question as above.

Sounds good.

Don’t put them in a subgroup. Use a consistent naming convention that clearly indicates date, source, and relation of the attachment to the main document. Use tags to indicate other attributes of the document that are interesting to you.

Now that I’ve written all that, I should say that there is no right way to do any of this – there are probably several hundred other readers who do things different than I described – and probably they didn’t write in because they know “it depends”. The test is: can you find what you want when you want it and where you expect to find it?

(I have a sneaky suspicion I didn’t adequately answer because there’s actually another question. :cry:)

i didn’t respond out of ignorance. as i understand it (or don’t, i guess), an “attachment” in a word file is something imported into it, and therefore embedded, so it doesn’t matter what happens to the original attached files.

but, let’s assume i am wrong (a safe assumption) and that the attachments have to be located in a stable location of some kind. korm’s advice about indexing, then, is the best. it is a totally non-invasive way to handle your files and still respect their finder locations. here is a blog post of mine about indexing:
christopher-mayo.com/?p=2376

i’m a heavy user of replicants these days. they have their pros and cons, but i’ve found they fit my use case well. as for filename changes, it isn’t an issue for me, because i follow certain naming conventions of my own to avoid issues (generally yyyymmdd_keyword_keyword_etc).

i’ve generally given up on tags, except in a few special cases. apple doesn’t provide a robust enough way to manage them, and while dt is actually pretty good with tags overall, it is still far better suited for groups. tags have a lot of potential,and i think there is a great opportunity for some enterprising developers to make a breakthrough with them, but right now, replicants and groups seem to be more than sufficient for my needs.

generally speaking, smart folders, replicants, and groups pretty much form the core of my own organization scheme. i try to take advantage of dt’s ai and keep my organizational work to a minimum. perhaps some screenshots of your database / finder files would help us offer more targeted advice.

One approach to associating email messages to their attachment file(s) that have been separately opened/captured to the DEVONthink database would be to create Annotation notes for the email messages that contain the attachments. I’ve kludged an approach that meets my needs.

The Annotation note will be a rich text document that is linked both to and from the email message. The link in the Annotation note to the referenced message contains the Name of the email document. Normally, the URL field in the referenced email message contains a “mailto” email address. But if an Annotation note is added to an email document, that URL is moved to the Spotlight Comments field of its Info panel and is prefaced by the string “Original URL”. The URL field in the Info panel now contains the DEVONthink URL of the Annotation note.

Attachments to email are not indexed or searchable. In order to make their content available in a database they must be separately opened and saved to the database. The attachments are available to open when the Text Alternative button in the navigation bar immediately above the pane in which the message is displayed. When opened in their parent application they can be saved to the Inbox location in the Finder, which sends them to the Global Inbox.

Where to file them?

I move them from the Global Inbox to a group named Email Attachments in the same database that contains the “parent” email message. Then in the Annotation note linked to the email that held the attachment(s) just saved and filed, I enter a “header” for the list of attachments, then copy/paste the Item Link (Edit > Copy Item Link) of each attachment into the relevant Annotation note.

Here’s the set of kludges that pull this together, so that I can identify all email messages that had attachments that I separated out and saved, or identify the saved attachments of an email message, or identify the “parent” email that contained a document located in the Email Attachments group.

  1. To identify emails that contain saved attachments, I can create a smart group for that purpose. In the full Search window I search the Comment field (Spotlight Comments) for the phrase “original url” and set the Advanced button as follows:
    All of the following are true:
    Kind is email
    In the full Search window, click on the “+” button to create a new smart group, then name and save it.

  2. To see a list of the saved attachments for any email listed in the above smart group, I can do an All search for the phrase “attachment list” – which I use as a convention in Annotation notes created for this purpose, to preface the Annotation note’s list of attachment documents that have been saved. (If that convention isn’t sufficiently unique, perhaps I might use an unusual string such as xylophone, instead.) If I then select and open a document that’s listed, I’m looking at the Annotation note of an email message. I see the (clickable) Name of the message and the (clickable) Names of the saved attachment documents.

By clicking on the link in the Annotation note to the referenced document, I see the email message that contains the attachment.

  1. If I wish to file an attachment document contained in the Email Attachments group to another location as well, I will usually duplicate the attachment document rather than replicate it. This is consistent with the convention of Mail that messages cannot be edited. If I do edit such a document, I’ll do it in another location so that the original copy isn’t affected.

Comments: My approach is manual. I get very few emails that contain attachments that would be useful in one of my databases. If I got hundreds of emails with attachments daily, my kludges would take a lot of time and effort. For my limited needs, my approach works.

The developer has hinted that at some point in the future it will be possible to index attachments, making them searchable. That would be great!

hi bill. i found your post very informative, and i’ll give that a try for my own use case, but i think the op was talking about “attachments” to documents, something i understood to mean data imported into a word document, but i could be mistaken. at any rate, the op doesn’t seem to be having issues with email attachments.