Divide the data into 2 set
- 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
I have dataset which contains 100 rows of records. I need to split / divide into 50 and 50 records (i.e., first 50 records and last 50 records). How can I do it in Alteryx?
I unable to get the correct output using 'Sample' tool. Please help.
Solved! Go to Solution.
- Labels:
- Data Investigation
- Datasets
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Please make use of the record ID tool.
Then filter based on record ID.
The F and T node will have 50 items each as 2 different datasets for you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hey @ravikumar060987 the sample approach you mentioned should work - you just need 2 streams. The first you'll sample the First N, where N = 50 & the second, you'll Skip First N, again where N = 50. Here's a quick example where I've generated 100 rows:
1-50 in the first Sample:
51-100 in the second Sample:
And the 2 outputs:
You can also do this in a single Output Data tool. Just set the Max Records Per File to 50 and Alteryx will automatically generate multiple:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
