How to get the Filepath from an yxdb file input
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hey all. Cannot find much information on this problem.
If i use an yxdb as file input, and connect field info tool to extract the filepath of the yxdb file i get the "SELECT * FROM *DB Table* instead of the actual filepath.
For some of the fields, it lists the tools e.g. crosstab, that has been used to manipulate the data before it was output to the yxdb file in the first place.
The data in the yxdb is downloaded from an oracle database through Alteryx, data has been manipulated etc. then output to the yxdb file that i want to find filepath/location from.
Using a directory tool to get the filepath is not an option, as this is what i need the filepath for to do in the first place. To direct a directory tool in a macro.
Also i would like to avoid using the output file name as field as i cannot be sure the users of the macro will do this.
EDIT: Addet example
Text input to fill yxdb with data.
Then load yxdb and try to get filepath. It will list the text input as its source instead of the file location.
So, any workarounds to get the filepath ?
\\Simon
Solved! Go to Solution.
- Labels:
- Help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Simon
You can get the FilePath by turning on this option in the Input Data tool:
It will output the FilePath as an extra column.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Sorry, i forgot to write this.. Just updated, as i cannot use this solution either. The users of the macro will not know that this is nessescary.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
If you require a specific field to be input to your macro, I recommend that the best way to do this is to require users to map the field in the macro configuration, and to provide some instructions if you think they will need it.
I have attached an example of what this might look like - the example doesn't actually do anything, but it does force the user to select their filepath field and ensures it is correctly identified, regardless of what they have named it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I will mark this as the solution, as it at least forces the user to actively choose the right field containing filename.
Thank you.
