on 10-30-2007 2:01 PM
Hi all
I am using MDM Java APIs(new). I also had not worked on MDM4J earlier.
Now the scenario is simple enough:
I have to search the Products table.
I have got the connection, established session , done user authentication and all.
Now the problem is setting the search parameter and constraint, that means i need to add some piece of code after this
Search search = new Search(mainTableId);
I am not able to figure out that.
Moreover when i get the resultset, how I retrieve the specific values (field wise) from it, i mean which methods to use (api).
If there is some reference guide for new API's ,it would be great (the one at service market place is corrupt, MDM 5.5 Java Library Reference Guide)
Any pointers are most welcome
Avinash
Well I was also trying the same methods...and as I have the data in the form of a result set , it is more of a question of manipulating the result set to achieve the desired results.
Thanks Everyone
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
The Javadoc for the MDM Java API contains a package called com.sap.mdm.examples, where you can find an example of what you are looking for.
Walter
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Avinash,
The field values that are to be retrieved should be mentioned in ResultDefinition.
After the command is executed you can retrieve the value by rs.getRecord(i).getFieldValue(<FieldID>).toString()
For the LookUp flat values it will retrieve the RecordID of that value rather than the value itself. From the RecordID fetch the value using RetrieveRecordsByID command.
Thanks
Namrata
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try going to www.service.sap.com/installMDM there are some examples and tutorials available. For what to put after creating the search look in the MDM API javadocs for SearchConstraint and SearchDimension which are the interfaces you will need. For example to search for all records where a text field is a particular string you would put.
FieldSearchDimension fsd = new FieldSearchDimension(<Field to search ID>);
TextSearchConstraint tsc = new TextSearchConstraint(<String to search for>, TextSearchConstraint.EQUALS);
search.addSearchItem(fsd,tsc);
Hope this helps,
Greg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.