Best option to push Mass data using Java API
Hi All,
Can any one let me know how Java API push data to MDM? Is it a good option when ti comes to perfromance point of view? We have around 2000/5000 records to be imported every time using Java API and wondering what would be best way to acheive this using Java API?
Is java API is best option than Web services?
Thanks
Rajeev
Rajeev,
It is perfectly fine to use API to push data into MDM, you just need to make sure that your API does all those tasks which import manager does by default. For example, it should know when to insert and when to update. if an error happens during insertion of record, you should be able to notify the users.
Having said that, where does the number 2000/5000 comes in? will you be creating users in batch and then invoke MDM API to store these in a single shot or willl it be a delta insert/update from Java to MDM?
Thanks
Aamir
Similar Messages
-
How to get the context data using java script in interactive forms
Hi All,
How to get the context data using java script in interactive forms by adobe, am using web dynpro java
thanks.Hi venkat,
Please Refer this link.
Populating one Drop-Down list from the selection of another Drop-down list
Thanks,
Raju. -
Using the Data Engine Java API
I try to use the Data Engine Java API to generate an XML document from database data.
So as mentioned in the documentation Business Intelligence Publisher User's Guide Release 10.1.3.2 (page 4-26 to 4-27)
a) I created a java class (using Jdev Version 11.1.1.0.0)
package oracle.apps.XMLPublisher.client;
import com.sun.java.util.collections.Hashtable;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import oracle.apps.xdo.XDOException;
import oracle.apps.xdo.dataengine.DataProcessor;
public class XMLFileGenerator {
public XMLFileGenerator() {
public static void dataEngine() throws ClassNotFoundException, Exception {
XMLFileGenerator xMLFileGenerator = new XMLFileGenerator();
try {
//Initialization instantiate the DataProcessor class//
DataProcessor dataProcessor;
dataProcessor = new DataProcessor();
//Set Data Template to be executed
dataProcessor.setDataTemplate("PERFRBS.xml");
Hashtable parameters;
parameters = new Hashtable();
parameters.put("P_LEGAL_ENTITY_ID", "3259");
parameters.put("P_TRU_ID", "3262");
parameters.put("P_YEAR", "2009");
dataProcessor.setParameters(parameters);
// Now set the jdbc connection to the database that you
// wish to execute the template against.
// This sample assumes you have already created
// the connection object 'jdbcConnection'
Class.forName("oracle.jdbc.OracleDriver");
String url =
"jdbc:oracle:thin:@ap6005sdb.us.oracle.com:1526:hremeadv";
Connection jdbcConnection;
jdbcConnection= DriverManager.getConnection(url, "apps", "*****");
dataProcessor.setConnection(jdbcConnection);
System.out.println("Here1");
// Specify the output directory and file for the data file
dataProcessor.setOutput("BilanSocial.xml");
System.out.println("Here2");
dataProcessor.processData();
System.out.println("Here3");
} catch (SQLException e) {
System.out.println("SQLException " + e.getMessage());
} catch (XDOException e) {
System.out.println("XDOException" + e.getMessage());
public static void main(String[] argv) throws ClassNotFoundException,
Exception {
XMLFileGenerator xmlPublisher = new XMLFileGenerator();
XMLFileGenerator.dataEngine();
b) to generate my xml file based on the following data template
<?xml version="1.0" encoding="ISO-8859-1" ?>
<dataTemplate name="PERFRBS" defaultPackage="" version="1.0">
<parameters>
<parameter name="P_LEGAL_ENTITY_ID" dataType = "number"></parameter>
<parameter name="P_TRU_ID" dataType = "number"></parameter>
<parameter name="P_YEAR" dataType = "number"></parameter>
</parameters>
<lexicals>
</lexicals>
<dataQuery>
<sqlStatement name="Q_INDICATORS">
<![CDATA[ SELECT pai.action_information3 YEAR,
pai.action_information17 INDICATOR_VALUE
FROM pay_action_information pai
WHERE pai.action_information_category = 'HR_FR_BS'
AND pai.action_context_type = 'PA'
AND pai.action_information1 = :P_LEGAL_ENTITY_ID
AND pai.action_information2 = :P_TRU_ID
AND pai.action_information3 = :P_YEAR
]]>
</sqlStatement>
</dataQuery>
<dataStructure>
<group name="G_YEARS" dataType="varchar2" source="Q_INDICATORS">
<element name="YEAR" dataType="varchar2" value="YEAR"/>
<element name="INDICATOR_VALUE" dataType="number" value="INDICATOR_VALUE"/>
</group>
</dataStructure>
</dataTemplate>
---> But when I run it , it fails when calling the data processor with the following error
D:\Jdeveloper11g\jdk\bin\javaw.exe -client -classpath "D:\Jdeveloper11g\jdevhome\XMLPublisher\src\Client\classes;D:\BI publisher\XMLP562_WIN\XMLP562_WIN\manual\lib\versioninfo.jar;D:\BI publisher\XMLP562_WIN\XMLP562_WIN\manual\lib\xdocore.jar;D:\BI publisher\XMLP562_WIN\XMLP562_WIN\manual\lib\collections.jar;D:\BI publisher\XMLP562_WIN\XMLP562_WIN\manual\lib\xmlparserv2-904.jar;D:\BI publisher\XMLP562_WIN\XMLP562_WIN\manual\lib\i18nAPI_v3.jar;D:\Jdeveloper11g\jdbc\lib\ojdbc14dms.jar;D:\Jdeveloper11g\jlib\orai18n.jar;D:\Jdeveloper11g\diagnostics\lib\ojdl.jar;D:\Jdeveloper11g\jlib\dms.jar" -Dhttp.proxyHost=emeacache.uk.oracle.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts= -Dhttps.proxyHost=emeacache.uk.oracle.com -Dhttps.proxyPort=80 -Dhttps.nonProxyHosts= oracle.apps.XMLPublisher.client.XMLFileGenerator
Here1
Here2
Exception in thread "main" java.lang.IllegalAccessError: tried to access class oracle.jdbc.driver.OracleStatement from class oracle.apps.xdo.dataengine.DBConnection
at oracle.apps.xdo.dataengine.DBConnection.setRowPrefetchSize(DBConnection.java:42)
at oracle.apps.xdo.dataengine.XMLPGEN.setRowPrefetchSize(XMLPGEN.java:1224)
at oracle.apps.xdo.dataengine.XMLPGEN.writeData(XMLPGEN.java:420)
at oracle.apps.xdo.dataengine.XMLPGEN.writeGroupStructure(XMLPGEN.java:281)
at oracle.apps.xdo.dataengine.XMLPGEN.processData(XMLPGEN.java:251)
at oracle.apps.xdo.dataengine.XMLPGEN.processXML(XMLPGEN.java:192)
at oracle.apps.xdo.dataengine.XMLPGEN.writeXML(XMLPGEN.java:222)
at oracle.apps.xdo.dataengine.DataProcessor.processData(DataProcessor.java:334)
at oracle.apps.XMLPublisher.client.XMLFileGenerator.dataEngine(XMLFileGenerator.java:50)
at oracle.apps.XMLPublisher.client.XMLFileGenerator.main(XMLFileGenerator.java:62)
Process exited with exit code 1.
Thanks by advance for your helpMake sure you have the Oracle JDBC library setup in project parties and it's setup to export. The api's are fine. Have you looked at the BIPublisherIDE I wrote. All this code is already written for you. There is a manual on the site as well
http://bipublisher.blogspot.com/2008/03/bi-publisher-bipublisheride.html
Ike Wiggins
http://bipublisher.blogspot.com -
How to convert MS SQL Server data to XML data using Java
Hi all!
How do I generate XML document for SQL Server data using java / jsp.
Thanks in advancehttp://www.fdsapi.com
-
Updating spatial data USING JAVA
I want to update spatial data using java.Does anyone know how can i do this;;;
for example i have created the following table.
CREATE TABLE customers (
customer_id NUMBER,
last_name VARCHAR2(30),
first_name VARCHAR2(30),
street_address VARCHAR2(40),
city VARCHAR2(30),
state_province_code VARCHAR2(2),
postal_code VARCHAR2(9),
cust_geo_location SDO_GEOMETRY);
HOW CAN I UPDATE THE FIELD:cust_geo_location,
WHICH TYPE IS: SDO_GEOMETRY;;;;;
I wrote a programm in java, which updates the FIELD CUSTOMER_ID.
( rset.absolute(3);
rset.updateInt("CUSTOMER_ID",2222 );
CUSTOMER_ID = rset.getInt("CUSTOMER_ID");
rset.next();
rset.updateRow(); ).
---------- THE FULL JAVA PROGRAMM
import java.sql.*;
import java.io.*;
import java.util.Date;
public class update{
public static void main (String args [])
throws SQLException, IOException
System.out.println ("Loading Oracle driver");
try {
Class.forName ("oracle.jdbc.driver.OracleDriver");
catch (ClassNotFoundException e)
System.out.println ("Could not load the driver");
e.printStackTrace ();
System.out.println ("Connecting to the local database");
try{
Connection conn =
DriverManager.getConnection("jdbc:oracle:thin:@127.0.0.1:1521:XE", "sp", "spgianna");
Statement stmt = conn.createStatement (ResultSet.TYPE_SCROLL_INSENSITIVE,
ResultSet.CONCUR_UPDATABLE);
// String LAST_NAME,FIRST_NAME ;
int CUSTOMER_ID ;
ResultSet rset = stmt.executeQuery("SELECT CUSTOMER_ID FROM CUSTOMERS");
/* while ( rset.next() ) {
CUSTOMER_ID = rset.getInt("CUSTOMER_ID");
LAST_NAME = rset.getString("LAST_NAME");
FIRST_NAME = rset.getString("FIRST_NAME");
System.out.println( CUSTOMER_ID+""+LAST_NAME + " " +FIRST_NAME);
rset.absolute(3);
rset.updateInt("CUSTOMER_ID",2222 );
CUSTOMER_ID = rset.getInt("CUSTOMER_ID");
rset.next();
rset.updateRow();
System.out.println(CUSTOMER_ID);
catch(SQLException sqle) {
System.out.println("SQL Exception encountered: " );
} catch(Exception e) {
System.out.println("Unexpected Exception: " );
HOW CAN I UPDATE THE FIELD:cust_geo_location,
WHICH TYPE IS: SDO_GEOMETRY;;;;;;;;;;;;;;Hi Guys,
Dont forget to close your stmt and connection after execution
Use this as a template if you like:
try{
/**make connection**/
ServerConnection sc = new ServerConnection();
Statement stmt = sc.conn.createStatement();
/**create statement & execute**/
String insertstmt = "insert into .......";
//execute
stmt.execute(insertstmt);
/**Close and catch exception**/
stmt.close();
sc.conn.close();
catch(SQLException sqlE){
sqlE.printStackTrace();
System.out.println(sqlE.getMessage());
As for the string "insertstmt" itself, this is where your standard SQL statement goes
So get it working using a standard SQL editor first, then copy and paste it in to this string variable. The string should be a series of concatenated strings and variables to recreate the SQL atatement in Java. For example
the SQL statement:
insert into Mytable(SESSIONID, TIME1) values ('300', '4.45pm' );
assuming the values are stored in variables called 'sessionnumber' and 'time'
will become
String stmt =
"insert into Mytable(SESSIONID, TIME1) values ('"+sessionnumber+"', '"+time+"')";
Hope this helps.
E
Ps. Do a system.out.println after you create the stmt. The statement printed out to the console should be a valid SQL statement that you can use in your editor. (minus the ;)
...keep working on the string until you can do this. -
How to retrieve data from MDM using java API
hi experts
Please explain me the step by step procedure
how to retrieve data from MDM using java API
and please tell me what are the
important classes and packages in MDM Java API
thanks
ramuHi Ramchandra,
You can refer to following links
MDM Java API-pdf
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/2d18d355-0601-0010-fdbb-d8b143420f49
webinr of java API
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/89243c32-0601-0010-559d-80d5b0884d67
Following Fourm Threads will also help.
Java API
Java API
Re: usage of java API ,
Matching Record
Need Java API for Matching Record
Thanks and Regards,
Shruti.
Edited by: Shruti Shah on Jul 16, 2008 12:35 PM -
Need Sample Code for Vendor creation using JAVA API
Hi,
I have a scenario like Vendor creation using <b>Java API</b>.
1.I have Vendors (Main) Table.
2.I have <b>look up</b> tables like Account Group.
3.Also <b>Qualifier table</b>(Phone numbers) too.
Could you please give me the sample code which helps me to create Vendor records using Java API?
<b>I need Code samples which should cover all of the above scenario.</b>
<b>Marks will be given for the relevent answers.</b>
Best Regards
PK DevarajHi Devraj,
I hope the below code might solve all your problem:-
//Adding Qualified field
//Creating empty record in Qualifed table
//Adding No Qualifiers
Record qualified_record = RecordFactory.createEmptyRecord(new TableId(<TableId>));
try {
qualified_record.setFieldValue(new FieldId(<fieldId of NoQualifier), new StringValue(<StringValue>));//Adding No Qualifier
catch (IllegalArgumentException e2) {
// TODO Auto-generated catch block
e2.printStackTrace();
catch (MdmValueTypeException e2) {
// TODO Auto-generated catch block
e2.printStackTrace();
//Creating Record in Qualified table
CreateRecordCommand create_command = new CreateRecordCommand(connections);
create_command.setSession(sessionId);
create_command.setRecord(qualified_record);
try
create_command.execute();
catch(Exception e)
System.out.println(e.toString());
RecordId record_id = create_command.getRecord().getId();
//Adding the new record to Qualifed Lookup value and setting the Yes Qualifiers
QualifiedLookupValue lookup_value = new QualifiedLookupValue();
int link = lookup_value.createQualifiedLink(new QualifiedLinkValue(record_id));
//Adding Yes Qualifiers
lookup_value.setQualifierFieldValue(0 , new FieldId(<FieldID of Yes Qualifier>) , new StringValue(<StringValue>));
//Now adding LookUP values
//Fetch the RecordID of the value selected by user using the following function
public RecordId getRecordID(ConnectionPool connections , String sessionID , String value , String Fieldid , String tableid)
ResultDefinition rsd = new ResultDefinition(new TableId(tableid));
rsd.addSelectField(new FieldId(Fieldid));
StringValue [] val = new StringValue[1];
val[0] = new StringValue(value);
RetrieveRecordsByValueCommand val_command = new RetrieveRecordsByValueCommand(connections);
val_command.setSession(sessionID);
val_command.setResultDefinition(rsd);
val_command.setFieldId(new FieldId(Fieldid));
val_command.setFieldValues(val);
try
val_command.execute();
catch(Exception e)
RecordResultSet result_set = val_command.getRecords();
RecordId id = null;
if(result_set.getCount()>0)
for(int i = 0 ; i < result_set.getCount() ; i++)
id = result_set.getRecord(i).getId();
return id;
//Finally creating the record in Main table
com.sap.mdm.data.Record empty_record = RecordFactory.createEmptyRecord(new TableId("T1"));
try {
empty_record.setFieldValue(new FieldId(<FieldId of text field in Main table>),new StringValue(<StringValue>));
empty_record.setFieldValue(new FieldId(<FieldId of lookup field in Main table>), new LookupValue(<RecordID of the value retrieved using the above getRecordID function>));
empty_record.setFieldValue(new FieldId(<FieldId of Qualified field in Main table>), new QualifiedLookupValue(<lookup_value>));//QualifiedLookUp value Retrieved above
} catch (IllegalArgumentException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
} catch (MdmValueTypeException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
//Actually creating the record in Main table
CreateRecordCommand create_main_command = new CreateRecordCommand(connections);
create_main_command.setSession(sessionId);
create_main_command.setRecord(empty_record);
try
create_main_command.execute();
catch(Exception e)
System.out.println(e.toString());
Thanks
Namrata -
Image not displayed in pdf generated using Java API for Forms service
Hi,
I am creating a pdf document using Java API for Forms Service.
I am able to generate the pdf but the images are not visible in the generated pdf.
The image relative path is coming in the xml as defined below. The images are stored dynamically in the Livecycle repository each time a request is fired with unique name before the xml is generated.
<imageURI xfa:contentType="image/png" href="../Images/logo.png"></imageURI>
Not sure if I need to specify specify specific URI values that are required to render a form with image.
The same thing is working when I generate pdf document using Java API for Output Service.
As, I need to generate interactive form, I have to use Forms service to generate pdfs.
Any help will be highly appreciated.
Thanks.Below is the code snippet:
//Create a FormsServiceClient object
FormsServiceClient formsClient = new FormsServiceClient(myFactory);
//Specify URI values that are required to render a form
URLSpec uriValues = new URLSpec();
// Template location contains the whole rpository path for the form
uriValues.setContentRootURI(templateLocation);
// The base URL where form resources such as images and scripts are located. Whole Image path is passed in BaseUrl in the http format.
String baseLocation = repositoryPath.concat(serviceName).concat(imagesPath);
uriValues.setBaseURL(baseLocation);
// Set run-time options using a PDFFormRenderSpec instance
PDFFormRenderSpec pdfFormRenderSpec = new PDFFormRenderSpec();
pdfFormRenderSpec.setCacheEnabled(new Boolean(true));
pdfFormRenderSpec.setAcrobatVersion(com.adobe.livecycle.formsservice.client.AcrobatVersio n.Acrobat_8);
//Invoke the renderPDFForm method and write the
//results to a client web browser
String tempTemplateName =templateName;
FormsResult formOut = formsClient.renderPDFForm(tempTemplateName,
inXMDataTransformed,pdfFormRenderSpec,uriValues,null);
//Create a Document object that stores form data
Document outputDocument = formOut.getOutputContent();
InputStream inputStream = outputDocument.getInputStream(); -
How to upload Image to MDM 5.5 SP3 using Java APIs
Hi,
I am trying to upload Image to Images table in MDM 5.5 using JAVA API for MDM. But. I'm not able to find particular field in Images table where I need to set the Blob object ( Image data ).
I'm not aware of the method to set the Blob, there is one for getting the Image data.
I have gone through I am not able to add images into Catalog thru java API forums posts and tried the code. But with no luck....
I think this code is for some other MDM version as the fields mentioned are not present in the Images table e.g. DataObject - this field is used in the above posts to set the Blob data but this field does not exist in Images table in MDM 5.5
Can anyone suggest the solution?
Thanks and Regards,
MausamHi Mausam,
Please try the following:
// adding to a image table
// get the bytes for the image
byte[] imageBuf = readFile("C:\pic.bmp");
// setup A2iFields
fields = new A2iFields();
fields.Add(new A2iField("DataObject", new
Value(imageBuf))); // the image binary (required)
fields.Add(new A2iField("Name", new Value("pic.bmp")));
// a name for the image
fields.Add(new A2iField("OrigName", new
Value("pic.bmp"))); // the original image file name
(required)
fields.Add(new A2iField("DataGroupId", new Value(888)));
// the data group to add to (required)
fields.Add(new A2iField("OrigLocationId", new
Value(999))); // the data location of the image
(required)
fields.Add(new A2iField("Description", new Value("a
short description"))); // a short description here
// add the image
String imageTable = "Images";
catalog.AddRecord(imageTable, fields, -1, -1);
It's taken out of the API guide for SP3 (the example for method AddRecord.
Best regards,
Amit -
Can i create more than one attributes for the custom class created using java API
Hello everyone,
I have been creating class and its attributes programatically using java APIs, I want to know that is there any way to create multipal attributs for the same class in just one call of API with all the options for each attributes,
thanksYou can create a new class and define all of the Attributes at the time the class is created - this is the preferred way of creating classes. Use the addAttributeDefinition() method on ClassObjectDefinition. If you need to add attributes to existing classes, you can only add them one at a time (using the addAttribute() method on ClassObject).
(dave) -
How to find bpel instance in 11g based on the index values using Java APIs
Hi ,
In SOA10G we had option to find the instances based on the index value using Java APIs like below.
WhereCondition criteria= new WhereCondition(SQLDefs.CX_index_1 + " = ?");
criteria.setString(1, "indexValue");
Locator mLoc = getLocator();
IInstanceHandle[] foundInstances = mLoc.listInstancesByIndex(criteria);
Please tell me how to achieve the same functionality in SOA 11G using Java APIs
Regards,
SabaI have multiple bpel in my composite. I checked in ci_indexes table and it shows the instance number of the bpel process. But the em console is showing only the composite instance number. when I opened composite instance, I could see all the bpel process with instance number in the audit trail. How can I find the the actual composite instance number that I should search for in the em console ???
-
Can't display a Tile Layer using JAVA API V2 (based on HTML5)
Hi Experts,
I am trying to display a tile layer using JAVA API V2 but i get the below error and nothing shows after that.
MAPVIEWER-05501: Map tile layer not found. Check map tile layer name and/or data source name.
Source: OM.layer.Tilelayer.getTileLayerConfig
*[mvdemo.demo_map]*
I tried with chrome and firefox browsers which supports HTML5 but same issue. Here is the html code i am using
<html>
<head>
<title></title>
<meta http-equiv='Content-Type' content='text/html; charset=UTF-8'>
<script type='text/javascript' src='http://localhost:8282/mapviewer/jslib/v2/oraclemapsv2.js'></script>
<style type= 'text/css '>body {cursor:default;}</style>
<script language="JavaScript" type="text/javascript">
function showMap()
var baseURL = "http://"+document.location.host+"/mapviewer";
var mapCenterLon = -122.45;
var mapCenterLat = 37.6706;
var mapZoom = 4;
var mpoint = new OM.geometry.Point(mapCenterLon,mapCenterLat,8307);
var map = new OM.Map(
document.getElementById('map'),
mapviewerURL: baseURL
var tileLayer = new OM.layer.TileLayer(
"baseMap",
dataSource:"mvdemo",
tileLayer:"demo_map",
tileServerURL:baseURL+"/mcserver"
map.addLayer(tileLayer) ;
navigationPanelBar=new OM.control.NavigationPanelBar();
map.addMapDecoration(navigationPanelBar);
map.setMapCenter(mpoint);
map.setMapZoomLevel(mapZoom) ;
map.init() ;
</script>
</head>
</html>
Note: inside the body on load i use DIV Id = Map (i skipped that one line of code because it stops rest of the line from displaying in the thread)
However, I am successful in using the same tile Layer with JAVA API V1
Please share your thoughts as what could be the fix
Thanks
NagNag,
inside the body on load i use DIV Id = Map (i skipped that one line of code because it stops rest of the line from displaying in the thread)please surround your code with [ c o d e ] [ / c o d e ] (without the spaces).
Secondly: this is probably more appropriate for the {forum:id=727} forum.
Regards,
Stefan -
How to build a small application using Java API
Hai expertise,
I want to retreive MDM repository info using JAVA API, i am following these blogs:
/people/andreas.seifried/blog/2006/03/26/performing-free-form-searches-with-mdm-java-api
/people/udi.katz/blog/2005/08/21/retrieving-data-from-mdm-server-using-the-mdm-java-api
/people/udi.katz/blog/2005/07/17/mdm-connectivity-to-java-application
<b>where to get the jar and sda files to build the application??
In Developer Studio.. Windows -> Preferences -> Java -> Classpath variables. Is this the only place where we need to give the jar file path??
Are there any other configurations to do(except setting container variable to MDM4J jar file) to connect my java application to MDM repository???</b>
Regards,
Chand.Hi Govada,
(1)You need to add the MDM4j and other JAR files at:-
right click on project -> Java Build Path -> Libraries -> Add External JARs
(2)If the project is Web Dynpro project one
then right click on project -> Web Dynpro Reference -> Library Reference -> and add sap.com/com.sap.mdm.tech.mdm4j
Are you using JAVA API 1 or 2???
Thanking you
Namrata Dixit -
Uploading images whit thumbnail to MDM repository using Java API
Hello,
can someone tell me how to upload images whit thumbnail to MDM repository using Java API?
i get following message using setHasThumbnail(true):
com.sap.mdm.commands.CommandException: com.sap.mdm.internal.protocol.manual.ServerException: Ungültiger Wert für Parameter
thanksYou can upload images to MDM via the API, but the only way to create thumbnails is via the MDM Data Manager application which uses some embedded libraries to do the work.
Walter -
How to create the groups in OID Using Java API.
Hi,
I need to create the group in OID Using Java API's only(i.e., javax.naming.* only).
I need to achieve it without using any oracle specific jars.
Is there any way to achieve it?.If there's a option to achieve it,do let me know.
I also need to create the users in that group ,after creating it.
If you share any useful link or ideas for the same would be great.
Thanks
Balajibobws wrote:
Hi,
I want to find the installed JREs in windows using java. I couldn't fine any java API. So I am using the below code to fetch the JRE list from windows registries & parse the returned collection to know the installed JRE.Why? If you are running java you already have a JRE. So why not just use it?
>
String key = "HKEY_LOCAL_MACHINE\\SOFTWARE\\JavaSoft\\Java Runtime Environment";
Runtime.getRuntime().exec(
"reg query " + "\"" + key + "\"");
Is it legal to retrieve the installed JREs in this way? Legal? It is OS specific, and to a certain extent dependent on vendor and what the vendor wants to do. Could also be impacted by permissions. Other than that it is ok.
I am feeling like its a type of hacking. So I couldn't decide whether this is legal (recommended) way of using. Does anybody can answer me. I can see the similar posts in google. Somebody suggests this way & somebody suggests to use preference API which is similar to this. Appreciate your help.Preferences won't work. It doesn't allow access to the registry in general, only a part of it. There are discussions in the JNI forum about retrieving VM versions. Prior to actually using the VM though.
Maybe you are looking for
-
Any changes in PA30 need to send a mail to the Managers outlook inbox
Hi, Any changes in PA30 (ESS) need to send a mail to the Managers outlook inbox . Kindly let me know the Standard workflow template and to built the Custom function module in Rule . Thanks in advance, Richard A
-
How to know if this computer can handle a certain monitor's resolution?
I am looking to buy a new monitor, but I am at a loss as to how to know whether my computer can handle the monitor's resolution, will be compatible with it. I used to run two NEC Multisync FE991SB (CRT) monitors side by side, and one of them died. Th
-
Hi I am trying to install flash player and when it says installation complete nothing happens
-
Which of these 2 laptops would be my best choice for editing video?
I am going to get a new laptop mainly to use for LR and PS but I also want to be able to edit video. Which of these 2 laptops is my best option... ASUS ROG G751JT-CH71 Intel Core i7-4710HQ 2.5 GHz 16 GB DDR3 1000 GB 7200 rpm Hard Drive 17.3-Inch Scr
-
Help getting AVI files into PE12
I have AVI videos from some cheap Hitachi HD cameras which won't load in PE12. The files load as just audio, but play back fine on the computer. I've read the various threads on similar issues but haven't found a good work around yet. GSpot shows the