-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multi-file Join #134
Comments
Hey, good to see you back! So, there is a way to do this:
I agree though, the current |
Here's another way in the current tool. This will probably feel more natural than the first example I gave:
Both forms are doing similar things: join two files in the first The results of the two styles are the same if there are no duplicate keys. This is normally the case when doing this type of multi-file join operation. The time duplicate keys matters is when you are using one file as a filter on another the other. In that case, the "filter file" ( |
Ah, thanks for the tip. So generalising it looks something like this:
Only problem I have is I can't seem to convince this to deal with the situation where a later file has keys the first one does not. |
Hey there, been a while. :)
I just tired to use tsv-join on a bunch of files and was very surprised when it applied the filter file to each of them in turn. Is there an approach that lets me nicely pull them all together that I've missed?
Why?: One of the really nice things about
tsv-join
is, since you're working with a key, ordering doesn't matter and holes in the data can be mitigated. But it's clumsy to have to repeatedly join a whole pile of intermediate things to get an end result.To clarify: with the following data files...
left
centre
right
...I'd like to see something like this:
Instead, that just prints each file in turn. (N.B. I reused the filter file as a data file because I want to preserve the column ordering.)
Trying this instead...
...closer. Sort of. (I guess?)
This is the best I've got right now and I think it should be reliable but I haven't tested it on something substantial:
The text was updated successfully, but these errors were encountered: