Kinook Software Forums

Kinook Software Forums (
-   [UR] General Discussion (
-   -   One way sync from a folder to UR (

science2002 01-21-2020 04:13 AM

One way sync from a folder to UR
I try to keep my many files (in my case mainly ebooks, but could be photos, etc.) organized, using Windows explorer and adopting proper names and folder structure. Windows attribute fields (under right click-properties) are a mess being unreliable (WinFS was aimed to make order, but it never see the light).

UR Sync:
I thought a work-flow as the following in the attempt to use tagging (via UR keywords) and extra info to my ebooks.
1. Import a target folder (including its sub-folders with ebook & doc files) to UR. Then add keywords from there, and insert also from UR some extra info-notes as a child for each file imported as a link.
2. Use Sync again to update and "import" the new files from the targeted folder into UR again as a link.

Problem of Sync:
However, in my Sync with UR also the items I add within UR goes to my HD targeted folder. And when I sync again the whole folder these new files are "imported" again in UR. So I have now: the child note I added in UR, plus the same note "imported" from the folder. I do not want that. I do *not* like that what I add in UR goes in my folder. I like just the opposite.

I ask then if it is possible the following:
a) to Sync an "imported" folder in "one way", i.e. from the the folder Hard Disk to UR, but not vice versa.
b) Moreover, if I change a file position in the HD (for instance moving it from one sub-folder to another) is it possible for UR to keep track of any UR keyword or UR child it has been given within the application, by moving them to the new position of the file?

Thanks for any feedback

cnewtonne 01-21-2020 01:15 PM

Notes from UR help ... I think the answer to your question is to use 'search synchronization'

When an Info Item without a populated URL attribute is Synchronized, if it is a child of an Info Item containing a valid local or Outlook folder URL, the Info Item will be created in this external folder. In all other cases, the existing content and attributes are simply re-parsed for keywords.

For Search Info Items, the URL attribute must reference a local or Outlook folder and the process is unidirectional. See Search Synchronization for more details.

Search Synchronization works very similar to Folder and Outlook Sync, except that the URL attribute of a search must reference a local folder or Outlook folder (respectively). When the Search item is synced, the search is executed and the items located by the search are synchronized to the folder location specified by the Search Item's URL attribute.

It appears search sync goes from UR to a Windows folder. Not sure, if it goes the opposite direction.

science2002 01-21-2020 04:32 PM

Thanks @cnewtonne

> I think the answer to your question is to use 'search synchronization'

Reading the Help file, this may seem what I was looking after.

I tried to implement it, but I came up with nothing. Sorry for the dump question. How is a 'search synchronization' precisely done? No menus, or commands, are given in the help file. Can you offer some tips?

In my various attempts to find a 'search synchronization', I noticed also the following.
1. If one imports again and again the same folder from the Hard Disk (call it FolderA), Keywords (and other attributes) given within UR are preserved.

2. If one moves a file (call it FileB) in Win Explorer, and then imports FolderA again, the linked item to FileB is moved in UR as well, losing UR keywords and attributes. Within UR, an item with the same name remains also in the old position, losing the link (and I presume also the contents for those files that are not txt, rtf, pdf, etc) with FileB in the Hard Disk.

3. If one moves the linked item of FileB within UR from one subfolder to another and the imports again FolderA, there are still two items in UR of the linked FileB as in point 2. Contrary to point 2, however, the two items are linked together, and both of them refer to the same FileB in the Hard Disk.

The drawback of this type of work-flow is that the import command may take time if FolderA contains Terabytes of files, while an incremental synchronization should be faster (and probably safer).

kinook 01-21-2020 05:06 PM

One-way folder sync is not currently supported, but we will consider it.

And UR is not able to identify files that have been moved -- you would need to update the item's URL attribute in UR (and optionally move in UR) after moving on the file system.

If you create an item in UR within a synced folder, you do need to add a URL item attribute with a value of the folder + filename of the synced file (i.e., subfolder\Item Title.rtf for a text item) to prevent another item with that URL from getting created when syncing. Another option would be to use the Item Notes pane instead of creating a separate item.

kinook 01-21-2020 05:11 PM

Regarding search synchronization, see

It is one-way from UR.

science2002 01-22-2020 09:41 AM

Thanks @kinook to clarify further.

But my confidence with UR is still limited. I read the help file you suggested, even before your post. Yet I do really not understand how to proceed.

Let say that I have a FolderA in C:\Users\FolderA.
It contains two files FileB and FileC and one Sub-folderD.

My UR file is without any item, apart default templates, and a sibling blank Note-item I created.

Now it seems that I am stuck. What shall I do to perform a search synchronization? The Help file is too vague on this regard. Can you point to a tutorial or give simple basic steps?

A possible guess could be the follwing, but I doubt that can be called search synchronization, since I do not have done any "search" at all:

I set a URL attribute in my Note-Item, I created. I pointed the URL to C:\Users\FolderA. Than I performed on that Note-item the standard synchronization.

The advantage is that the items created in UR (let say a note-item as a child under FileB) do not go to FolderA in the HD. However, if one moves within UR the synchronized FileB to the Sub-folderD, there are two Item-notes now, besides of two FileB in UR (one in the old place, and one in the new place). However, while the two FileB show a small arrow to indicate that are linked to the same (Hard Disk) file, the two child UR notes-items do not show the same arrow in their icon, but in fact they are the same: changing one, changes the other.
The drawback is that by any reason one changes FileB (or whatever) from the Hard Disk moving it to Sub-folderD, all the child items created in UR and any keyword given by UR to FileB disappear at the next sync.

Thanks again

kinook 01-22-2020 10:56 AM

Search sync is one way from UR to the file system. You're wanting the opposite -- from file system to UR. You would need to use folder synchronization for that, which is currently two-way.

Regarding your question about preventing a second item from getting created with folder synchronization, if you create an item in UR within a synced folder, you would need to add a URL item attribute to that item, with a value of the folder + filename of the synced file.

science2002 01-26-2020 05:21 AM

I tested the following steps and they seem to work to a certain degree, for those that want to tag and organize their files inside a folder in the Hard Disk.

a) Create a note item in UR, called for instance MyFiles.
b) Import (as a child) a folder with its files from the HD.
c) Create any other item in UR as a child (or not) of MyFiles to organize for instance in categories or fields the files imported (as link).
d) Move the (linked) files imported in UR within items of point c).
e) Any further sync to the imported folder (see point b) will update external new files into UR, without changing the links with what is done in UR with the old ones.

A question that comes at this point is the following. Is there a way to change (the path of) the URL attribute in a mass form, i.e. for many (imported) files at once?

This could be necessary for a situation similar to this. One has the files in a folder called "New ebooks" that has been imported. So in UR the URL attribute is "C:\New ebooks", for each file imported (i.e. linked). After some time (a year) one wants to change the name of his HD folder in "Old ebooks 2019". To not disrupt the sync in UR, one would need to change in a mass way all the URLs with "C:\New ebooks" into the new URL "C:\Old ebooks 2019". Can one perform this mass replacement in UR?

kinook 01-26-2020 10:24 AM

One option would be to leverage relative paths:

1) Create folder C:\UR\New ebooks\books

2) Create .urd file at C:\UR\New ebooks

3) When importing the folder C:\UR\New ebooks\books, the URLs of folders/files imported from there will be stored relative (i.e., books\path\to\file.ext)

4) If New ebooks is renamed to Old ebooks 2019, the links will still be valid, or if the .urd file is moved to another path C:\UR\old ebooks 2019, which has a subfolder 'books', the relative paths will still match up with files in the relative subfolder.

The other option would be to use SQLite tools to mass update attribute values. See

science2002 01-27-2020 05:16 AM

Thanks @kinnok. I thought myself of your first solution (relative paths).
The fact in my case is that I usually have a folder structure like this

C:\UR\New ebooks\ (1)
C:\UR\Old ebooks 2019\ (2)

Then as time goes by the folder "New ebooks" becomes (2), i.e. "Old ebooks YYYY", etc.
I would like to have UR that keeps track of both (1) and (2), so its database is placed in folder UR. In this way, it exploits relative paths (no need to know the letter of the HDD), but I would still need to change the URL folder name from (1) to (2) when time comes.

I will look into your second method then. Thanks again.

kinook 07-27-2020 11:53 AM

Ability to perform one-way sync is implemented in v6.1. See for details (SyncDirection).

All times are GMT -5. The time now is 01:52 AM.

Copyright 1999-2021 Kinook Software, Inc.