Open nickolation opened 1 year ago
This question sounds like an XY problem: http://mywiki.wooledge.org/XyProblem
Can you supply an example program that illustrates as much as possible what you’re trying to do?
The way your question is currently worded, I could say “sure, just remove everything after the first 2 dots”. I’m not sure if the problem you’re facing is that the number of dots is variable, or something else entirely…?
For example, I have a fieldmask with paths = {a.b.c, a.b, a.x.d, a.g.f} I want to transform all paths containing more than 3 nodes so that only the first 2 nodes remain in them. Then remove the matches. In result i want {a.b, a.x, a.g} Is there an opportunity to do something like this?