Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How to validate data before submitting asset.

In RAM API we have method session.put for pushing the data in RAM.

Now is there any available method which will check for validate set attributes and category before submitting asset.

<b>Scenario</b> : Say I am submitting 20 asset, each with 5 MB of physical file thru excel batch upload. Now when my web client triggers batch upload, if there is some mandatory attribute missing in 18th asset, he will get the error message only after either all other assets are submitted (session.putassets) or initial seventeen assets submitted (session.put), which may take a long time.

So is there any way I can check for excel sheet data (asset attribute and category) validity, before actually using session.put..

0 votes



4 answers

Permanent link
You can use RAMAsset.validate() to return any validation messages about an asset.


In RAM API we have method session.put for pushing the data in RAM.

Now is there any available method which will check for validate set attributes and category before submitting asset.

<b>Scenario</b> : Say I am submitting 20 asset, each with 5 MB of physical file thru excel batch upload. Now when my web client triggers batch upload, if there is some mandatory attribute missing in 18th asset, he will get the error message only after either all other assets are submitted (session.putassets) or initial seventeen assets submitted (session.put), which may take a long time.

So is there any way I can check for excel sheet data (asset attribute and category) validity, before actually using session.put..

0 votes


Permanent link
RAMAsset.validate() return validation messages only for required fields. Niether this or RAMSession.put() throw invalid data error for optional fields. (for dropdown/select box attribute, in case of non-required attribute value its skipping that value and submitting other valid values in RAM, but not returning error for invalid values.)

Is there any method which will validate the asset irrespective of attribute condition??



You can use RAMAsset.validate() to return any validation messages about an asset.


In RAM API we have method session.put for pushing the data in RAM.

Now is there any available method which will check for validate set attributes and category before submitting asset.

<b>Scenario</b> : Say I am submitting 20 asset, each with 5 MB of physical file thru excel batch upload. Now when my web client triggers batch upload, if there is some mandatory attribute missing in 18th asset, he will get the error message only after either all other assets are submitted (session.putassets) or initial seventeen assets submitted (session.put), which may take a long time.

So is there any way I can check for excel sheet data (asset attribute and category) validity, before actually using session.put..

0 votes


Permanent link
As you mentioned, validation is driven by required fields.

Can you give an example of what is it that you are trying to verify, before submitting?

0 votes


Permanent link
You can use RAMAsset.validate() to return any validation messages about an asset.

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Aug 30 '10, 1:23 a.m.

Question was seen: 6,728 times

Last updated: Aug 30 '10, 1:23 a.m.

Confirmation Cancel Confirm