How do I create sequences in IFS

  • 497 Views
  • Last Post 11 January 2018
  • Topic Is Solved
Thatguy posted this 03 January 2018

Hello,

I am trying to create measurements for objects using "EQUIPMENT_OBJECT_MEAS_API" [See IMG1]

And 1 of the key fields is this “VALUES_SEQ” which has a default value that is supposedly a running index and will be unique: [IMG2]

So my question is, how do I derive this “Values_Seq” number and make it a running number too?

I managed to find another job that has this "Inventory_Location_Sequence.nextval" and using this method works but where did this method come from as there is no Inventory_Location_Sequence view/table.

 

Attached Files

Order By: Standard | Newest | Votes
Thatguy posted this 03 January 2018

I can't really copy and paste images as I get the error "6000 characters limit".

Unable to select other categories other than 'General' as well.  

 

//Probably the wrong place to post bugs report... so feel free to delete

 

  • Liked by
  • HelgaA
chana05 posted this 10 January 2018

Hello, 

You should use equipment_object_meas_seq.nextval

equipment_object_meas_seq is the name of the sequence and .nextval simply means you are getting the next sequenced value.

Note: when you do .nextval , oracle will automatically increase the sequence value. Even if you run an error creating new object measurement, the sequence will be incremented. 

  • Liked by
  • HelgaA
Thatguy posted this 10 January 2018

Thanks Chanaranga. How did you find for this method? I tried searching for .nextval but nothing came up.

  • Liked by
  • HelgaA
chana05 posted this 10 January 2018

If you go to EQUIPMENT_OBJECT_MEAS_API Insert method, you will see value_seq will be filled with above mentioned sequence.

Basically if you want to find which sequence is used, you can always check insert method or unpack_check_insert method (in app 8 and earlier)

  • Liked by
  • Thatguy
  • HelgaA
Thatguy posted this 11 January 2018

I will try that out. Thanks once again! 

  • Liked by
  • HelgaA
Close