Re: Dynamic segmentation with respect to a control factor Additional Requirements

7600
56
05-08-2015 08:06 AM
ChukwuemekaEzeiruaku
New Contributor II

I was able to figure out the error from earlier, but i have one more request.

If i have other fields in the table i want to also show on the out_table for example see table below:

   

DataUniqueIDItem IDBegin EndInput Table
Observation1555100001
555100105
555100217
555100345
555100435
Observation2600200103
600200226
600200335

   

DataUniqueIDBegin EndItem IDOutput Table
Observation1555011001
555131001; 1002
555341001; 1002; 1004
555451001; 1002; 1003; 1004
555571002
Observation2600022001; 2002
600232001; 2002
600352002; 2003
600562003

Is there a way to differentiate between records that are within a certain range(with UniqueID) as shown in the table above, plus have other fields for that range (with same uniqueID) in the output table?

I am really grateful for your help thus far guys, Thanks.

0 Kudos
56 Replies
ChukwuemekaEzeiruaku
New Contributor II

i see, yea there are a few missing data for dates

0 Kudos
BlakeTerhune
MVP Regular Contributor

Is that a data cleanup issue or does the code need to accommodate missing dates?

0 Kudos
ChukwuemekaEzeiruaku
New Contributor II

it's not a clean up issue, the data is expected to have missing data..

It'll be nice to have the code to accommodate for missing dates...

0 Kudos
ChukwuemekaEzeiruaku
New Contributor II

If the dates will be a pain i'll suggest we kill it and make the output table to include just the UniqueID, Begin and End, SegmentItems

0 Kudos
BlakeTerhune
MVP Regular Contributor

I updated the code to accommodate missing dates. Attached is the updated code and copy of the output table. I did brief review of the output and there doesn't seem to be any duplicate segments. The only possible issue I see is that it is creating segments that do not have an ItemID. This is because there is a gap in begin and end values. See UniqueID 1446100 for an example.

0 Kudos
ChukwuemekaEzeiruaku
New Contributor II

Awesome Thanks, but there is no attachment to your reply

0 Kudos
BlakeTerhune
MVP Regular Contributor

You don't see this?

0 Kudos
ChukwuemekaEzeiruaku
New Contributor II

Nope, i can see just the text and not the attachments..

0 Kudos
BlakeTerhune
MVP Regular Contributor

Check out Re: Some users unable to get attachments.

Timothy Hales said:

Make sure you open the discussion up and are not viewing it in your Inbox or Activity Stream.
0 Kudos
ChukwuemekaEzeiruaku
New Contributor II

I can't find any discussion button in the page

0 Kudos