Connectivity in flex to oracle using java
hello,
i have to connect flex 3 with java which uses oracle as a database.How i can connect flex with java.I am trying to access web services provided by java in flex.Is it possible? Please help me out.
Thanks,
Hi,
Are you using Flash Builder to build your application?
Definitely you could connect to web services from flex .
May be in your case, expose the JAVA class as web services using AXIS(may be) and access it as shown below:
Sample snippet:
<mx:WebService
id="service"
result="onResult(event)"
fault="onFault(event)"
wsdl="http://abc.cd.com/ PhoneNumber.asmx?WSDL/>
Refer: http://livedocs.adobe.com/flex/3/html/help.html?content=data_access_3.html for more details.
Please revert back if you face any issue
Thanks,
Balaji
http://balajisridhar.wordpress.com
Similar Messages
-
Is it possible to connect Sqlfire server with oracle using DBSynchronizer using default license
is it possible to connect Sqlfire server with oracle using DBSynchronizer using default license
Sql fire is my machine
Oracle is another machine
When i connect sqlfire with oracle using DBsynchronizer It shows the error message as Wan is not supported for default license
When i connect Sqlfie(my system) with oracle( another system) using JDBC Rowloader .nothing is happening after some time it shows the error like"time out for pool connection to archive database.When i increase the time out also nothing is happening.
what is the reason for above two errors(I stated in the pragraph.)
is it beacuse of wan netwrok not supported by default evaluation license?
could you please explain?I don't think this has anything to do with a VMware product.
-
Error in connection to oracle using java
hi ,
i am tring to make a connection to oracle database using java with this code
public class DataBase {
public DataBase(){
Connection connection = null;
try {
// Load the JDBC driver
String driverName = "oracle.jdbc.dirver.OracleDriver";
Class.forName(driverName);
// Create a connection to the database
String serverName = "http://localhost:7777";
String portNumber = "1521";
String sid = "ora9i";
String url = "jdbc:oracle:thin:@" + serverName + ":" + portNumber + ":" + sid;
String username = "scott";
String password = "tiger";
connection = DriverManager.getConnection(url, username, password);
} catch (ClassNotFoundException e) {
JOptionPane.showMessageDialog(null,"Coud not find the database driver ");
// Could not find the database driver
} catch (SQLException e) {
JOptionPane.showMessageDialog(null,"Coud not connect to the database ");
// Could not connect to the database
public static void main(String[] args) {
new DataBase();
i always got the compilation error Coud not find the database driver
i am using oracle9i and jdk1.5.0_04 and my classpath is C:\oracle\ora92\jdbc\lib\ojdbc14.zip;C:\oracle\ora92\jdbc\lib\orai18n.zip
i am realy stuck with this so any one can help me with this probelm
thanks alot,thanks for your reply,
yes i changed the server name and i verified the location of the JDBC driver file(s) on my computer. any way i solved my problem.
you know there was a misunderstanding in what you mean by classpath, i thought that i have to change the classpath from control panel>system>advance>enviroment variable
and then select classpaht and edit it. i was doing this but this is didn't work.
then i don't know why i did that
i went to java program and select my project,right click on it and then select properties>java build path and then select "add external Jars" button and then i simply choose them and add them to my project. and finaly it worked.
thanks alot -
Connecting to Oracle using Java API
I'm fairly new to Oracle, but what I'm trying to do should be straight forward (at least that's what I thought). I'm simply trying to connect to an Oracle database using the latest java API (J2SE 1.4.1).
I downloaded JDBC OCI (type 2) driver form the Oracle Web site along with the appropriate DLL; however when I try to run the following two lines
String dbUrl = "jdbc:oracle:oci8:@test";
String user = "user";
String password = "password";
DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
Connection c = DriverManager.getConnection(dbUrl, user, password);
I get the following error message:
"java.exe - Entry Point Not Found
The procedure entry point slzsetevar could not be located in the dynamic link library oracore8.dll."
Please note that I am running under Windows 2000 Pro, have Oracle Client 8.1.5 installed, and am able to connect to the same Oracle database using ODBC and PowerBuilder native drivers.
Then I read somewhere that I should use 8.1.7 version of the Oracle client software, so I downloaded it from the Oracle Web site. However when I try to install it under Windows 2000 (by double-clicking on the setup.exe) nothing happens!!!
Any ideas?!Sorry, I should have been more specific. The error message I was referring to shows up in a pop-up windows when I try to run the program. The actual java error message (that shows up in the command prompt window) is as follows:
"Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\WINNT\system32\ocijdbc8.dll: The specified procedure could not be found
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1473)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1397)
at java.lang.Runtime.loadLibrary0(Runtime.java:788)
at java.lang.System.loadLibrary(System.java:832)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java:192)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:142)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:214)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:193)
at java.sql.DriverManager.getConnection(DriverManager.java:512)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at lookup.main(lookup.java:16)"
I'm running the program through Windows 200 Pro command prompt, and the version of java is, as I mentioned in the previous message, 1.4.1:
java -version
java version "1.4.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_01-b01)
Java HotSpot(TM) Client VM (build 1.4.1_01-b01, mixed mode) -
How to Store word doc in oracle using java
hi
toall
can any one tell me how to store word doc in oracle9i using java
byePlease refer to
http://www.databasejournal.com/features/oracle/article.php/3305771 -
Not able to connect to Lotus Domino server using java/corba
Hi
I am new to Lotus Domino server and Java.
I have INstalled Lotus Domino server5 on 1 machine and was successful in installing the Lotus client on another machine.
Throught the lotus client i am able to connect to the server and send and receive the mails.
Now I want to connect to the domino server using the Lotus Domino Tolkit for Java/Corba.
In this Toolkit they have given the sample code program ..
if I run the code I am getting the error
java.io.FileNotFoundException: http://<IPADDRESS>/diiop_ior.txtjava.io.FileNotFoundException: http://<IPADDRESS>/diiop_ior.txt
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:691)
at java.net.URL.openStream(URL.java:942)
at lotus.domino.NotesFactory.getIOR(NotesFactory.java:314)
at lotus.domino.NotesFactory.createSession(NotesFactory.java:66)
at IntroCorbaApp.run(IntroCorbaApp.java:65)
at java.lang.Thread.run(Thread.java:539)
lotus.domino.NotesException: Could not get IOR from HTTP Server
lotus.domino.NotesException
at lotus.domino.NotesFactory.getIOR(NotesFactory.java:344)
at lotus.domino.NotesFactory.createSession(NotesFactory.java:66)
at IntroCorbaApp.run(IntroCorbaApp.java:65)
at java.lang.Thread.run(Thread.java:539)
I also tried to find this file in the Domino server directory.
The file exists in drive:\LotusServer\Domino\Data\Domino\HTML directory..
I am not getting what exactly is the Problem
Plz any one help me in this regard..
thanks in advanceYou should be able to access the diiop_ior.txt file from browser without authentication,only then it will work. This file should not
be protected. -
Connecting to http web site using java socket
Hi,
Sockets in Java I believe are reusable. Once created, it can be used to send a request using its input stream and get back a response using the output stream. My problem is I am trying to connect to a website using java socket but I am unable to get a response (though the same works fine I use URL and URLConnection). Can anyone tell me whats wrong? Below is the client program:
public class HttpAdapterTest {
public static void main(String[] args) {
try {
Socket socket = new Socket("www.google.com", 80);
BufferedWriter out = new BufferedWriter(
new OutputStreamWriter(socket.getOutputStream()));
out.write("GET /help/basics.html HTTP/1.1");
out.flush();
BufferedReader in = new BufferedReader(
new InputStreamReader(ucon.getInputStream()));
String line = null;
while((line = in.readLine()) != null) {
System.out.println(line);
in.close();
} catch (Exception e) {
e.printStackTrace();
}Look at the JSSE examples. You need to setup a key store, add the jsse jars to your classpath, yadda, yadda, yadda....
-
Error connecting GSM Modem with system using java (error no is 20)
hi!
I'm new to jms, i want to send sms using GSM Modem.I used sony Ericsion mobile. I got one sample application , when i run it thows the following exceptions.
Feb 27, 2008 4:31:27 PM org.jsmsengine.CSerialDriver open
INFO: Connecting...
Feb 27, 2008 4:31:28 PM org.jsmsengine.CSerialDriver close
INFO: Disconnecting...
Connection to mobile failed, error: -20
i used the following code
import org.jsmsengine.*;
class SendMessage
public static void main(String[] args)
int status;
// Create jSMSEngine service.
CService srv = new CService("COM6",9600);
System.out.println();
System.out.println("SendMessage(): sample application.");
System.out.println(" Using " + srv._name + " " + srv._version);
System.out.println();
try
// Initialize service.
srv.initialize();
// Set the cache directory.
srv.setCacheDir(".");
// Set the phonebook.
// srv.setPhoneBook("../misc/phonebook.xml");
// Connect to GSM device.
status = srv.connect();
// Did we connect ok?
if (status == CService.ERR_OK)
// Set the operation mode to PDU - default is ASCII.
srv.setOperationMode(CService.MODE_PDU);
// Set the SMSC number (set to default).
srv.setSmscNumber("");
// Print out GSM device info...
System.out.println("Mobile Device Information: ");
System.out.println(" Manufacturer : " + srv.getDeviceInfo().getManufacturer());
System.out.println(" Model : " + srv.getDeviceInfo().getModel());
System.out.println(" Serial No : " + srv.getDeviceInfo().getSerialNo());
System.out.println(" IMSI : " + srv.getDeviceInfo().getImsi());
System.out.println(" S/W Version : " + srv.getDeviceInfo().getSwVersion());
System.out.println(" Battery Level : " + srv.getDeviceInfo().getBatteryLevel() + "%");
System.out.println(" Signal Level : " + srv.getDeviceInfo().getSignalLevel() + "%");
// Create a COutgoingMessage object and dispatch it.
// *** Please update the phone number with one of your choice ***
COutgoingMessage msg = new COutgoingMessage("+919830645175", "Ripon");
// Character set is 7bit by default - lets make it UNICODE :)
// We can do this, because we are in PDU mode (look at line 63). When in ASCII mode,
// this does not make ANY difference...
msg.setMessageEncoding(CMessage.MESSAGE_ENCODING_UNICODE);
if (srv.sendMessage(msg) == CService.ERR_OK) System.out.println("Message Sent!");
else System.out.println("Message Failed!");
// Disconnect from GSM device.
srv.disconnect();
else System.out.println("Connection to mobile failed, error: " + status);
catch (Exception e)
e.printStackTrace();
System.exit(0);
In my jre path i added win32.dll to use comm.jar
please help meThanks so much; you just helped me fit together the last few pieces of this puzzle. I did a little more digging and found a [url http://support.webecs.com/KB/a375/how-do-i-configure-sql-server-express-to-allow-remote.aspx]knowledge base article that explains how to set a static TCP port. According to the article, SQL Server 2005 selects a random dynamic port on installation, and my experience bears out the fact that it does survive server reboots.
TheAvalanche wrote:
If you don't want that, make sure the SQL Server Browser service is running and connect to your SQL Server using the instance name, and not use a port in the JDBC-url.
BTW: I am not sure if jtds supports usage of the browser service, the Microsoft SQL Server JDBC drivers since version 1.2 (I think) do.It would appear that jTDS doesn't support the browser service, at least not by default, because I tried using the instance name rather than the port to connect (along with just about every other possible combination) and it didn't work. In my opinion, using a static port makes a lot more sense anyway, since you don't have to rely on the browser service, and you'll always know what port to set in your firewall exceptions. (For anyone out there wondering about firewall exceptions, in addition to the static port for the server, an exception has to be created for the browser on UDP 1434 if you're going to use it, which most programs apparently do.)
Once again, thanks for all the good information!
Edited by: javadecaf on May 27, 2011 8:03 AM
Insert link button on toolbar generated link syntax that doesn't work: text. What's up with that? -
User permission issue in connecting to Oracle using java in Cent OS
Hi ,
I am facing a peculiar issue and since I am new to Cent OS, I hope somebody can help me.
I am using Cent OS 4.2 and I installed Oracle client 10.2 in cent os 4.2.
I am having a java application which connects to Oracle server in another Linux system using Oracle OCI driver which comes along with Oracle client
I have a user called user1 which belongs to group group1 as primary group and my application runs under this user user1.
This user is a member of oinstall group (which is the group for oracle uesr which has access to oracle client directories/files)
But when my application tries to connect to Oracle server, I am getting connectivity error saying "Oracle driver not found" or "cannot load libocijdbc10.so". All environment variables like ORACLE_HOME, PATH,CLASSPATH, LD_LIBRARY_PATH are set properly.
The permissions to Oracle folder/files are rwx for owner(oracle user) , rx for group(oinstall) and none for others
What we observed are
1. When the application is start under root user, it works
2. When we give rx permission to others, it works
3. When we make oinstall group as the primary group for my user user1, it works
My questions here
1. Why it is not working even though my user user1 is a member of oinstall group
2. Why it is working when I make oinstall as the primary group
3. Is there any difference in security policy of RHEL and Cent OS
4. How can I access libraries from multiple folders which created by different user and belongs to different groups, if this is the case
I never faced this issue in RHEL4
Hope some body can help me.
Regards
SunilSorry, I should have been more specific. The error message I was referring to shows up in a pop-up windows when I try to run the program. The actual java error message (that shows up in the command prompt window) is as follows:
"Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\WINNT\system32\ocijdbc8.dll: The specified procedure could not be found
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1473)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1397)
at java.lang.Runtime.loadLibrary0(Runtime.java:788)
at java.lang.System.loadLibrary(System.java:832)
at oracle.jdbc.oci8.OCIDBAccess.logon(OCIDBAccess.java:192)
at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:142)
at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:214)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:193)
at java.sql.DriverManager.getConnection(DriverManager.java:512)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at lookup.main(lookup.java:16)"
I'm running the program through Windows 200 Pro command prompt, and the version of java is, as I mentioned in the previous message, 1.4.1:
java -version
java version "1.4.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_01-b01)
Java HotSpot(TM) Client VM (build 1.4.1_01-b01, mixed mode) -
Save Attachment from exchange server 2010 from oracle using java mail API
Hello,
I want to read email from microsoft exchangeserver 2010 and save attachement into a folder.I created an Java program to import attachments from a exchange server mailbox using "POP3S".It works fine when run as a java application.But when i put this inside Oracle11g R2 using load java and while executing from a procedure it gives an error at parsing message into Multipart
Error at line : Multipart mp = (Multipart)m.getContent();
Error:
Content-Type: multipart/mixed;
boundary="_002_A0C2E09A..................................."
java.lang.ClassCastException
at mailPop3.checkmail(mailPop3:71)
My Java Class is as follows,
import java.io.*;
import java.util.Properties;
import javax.mail.*;
import javax.mail.internet.*;
import java.util.Date;
The function i used to check for attachments is given below.
public static boolean hasAttachments(Message m) throws java.io.IOException, MessagingException
Boolean hasAttachments = false;
try
// if it is a plain/html text - no attachements
if (m.isMimeType("text/*"))
return hasAttachments;
else if (m.isMimeType("multipart/alternative"))
return hasAttachments;
else if (m.isMimeType("multipart/*"))
Multipart mp = (Multipart)m.getContent();
if (mp.getCount() > 1)
hasAttachments = true;
return hasAttachments;
catch (Exception e) {
e.printStackTrace();
} finally {
return hasAttachments;
My Java Details as follows
java Version :1.5.0_10
java.vm.specification.version:1.0
java.vm.version :1.5.0_01
java.specification.version:1.5
java.class.version:48.0
Java mail API:javamail-1.4.4
Used Jars:mail.jar
Could someone explain why I am getting this error? What can I do to resolve this error?
Is any other Jar need other than mail.jar?
Any help would be much appreciated.
Regards,
NisanthHai EJP,
Thanks for your reply,
My full java class as follows,
import java.util.Properties;
import javax.mail.Authenticator;
import javax.mail.Folder;
import javax.mail.Message;
import javax.mail.PasswordAuthentication;
import javax.mail.Session;
import javax.mail.Store;
import javax.mail.Part;
import javax.mail.Multipart;
import javax.mail.internet.MimeMultipart;
import javax.mail.internet.MimeMessage;
public class Newmail
public Newmail()
super();
public static int mailPOP3(String phost,
String pusername,
String ppassword)
Folder inbox =null;
Store store =null;
int result = 1;
try
String host=phost;
final String username=pusername;
final String password=ppassword;
System.out.println("Authenticator");
Authenticator auth=new Authenticator()
protected PasswordAuthentication getPasswordAuthentication()
return new PasswordAuthentication(username, password);
System.out.println("Certificate");
String filename="D:\\Certi\\jssecacerts";
String password2 = "changeit";
System.setProperty("javax.net.ssl.trustStore",filename);
System.setProperty("javax.net.ssl.trustStorePassword",password2);
Properties props = System.getProperties();
System.out.println("host-----"+props);
props.setProperty("mail.pop3s.port", "993");
props.setProperty("mail.pop3s.starttls.enable","true");
props.setProperty("mail.pop3s.ssl.trust", "*");
Session session = Session.getInstance(props,auth);
session.setDebug(true);
store = session.getStore("pop3s");
System.out.println("store------"+store);
store.connect(host,username,password);
System.out.println("Connected...");
inbox = store.getDefaultFolder().getFolder("INBOX");
inbox.open(Folder.READ_ONLY);
Message[] msgs = inbox.getMessages();
System.out.println("msgs.length-----"+msgs.length);
result = 0;
int no_of_messages = msgs.length;
for ( int i=0; i < no_of_messages; i++)
System.out.println("msgs.count-----"+i);
System.out.println("Attachment....>"+msgs.getContentType());
Multipart mp = (Multipart)msgs[i].getContent();
System.out.println("Casting Success" + mp.getContentType());
catch(Exception e)
e.printStackTrace();
finally
try
if(inbox!=null)
inbox.close(false);
if(store!=null)
store.close();
return result;
catch(Exception e)
e.printStackTrace();
return result;
Please check it
Regards,
Nisanth -
Insert multiple records into Oracle using Java
Hi,
Has anyone tried to insert multiple records into an Oracle table from Java? I have my data in a Java collection.Can I send a Java Collection to an Oracle Package as a PL/SQL Table Type? My problem is I dont want to instantiate a CallableStatement object everytime I do an insert. Instead I want to do that only once and then insert multiple records in one operation.
Any suggestions will be appreciated,
Thanks,
AlexHi Mensa,
I went thru the code example in your book in chapter 8 (downloaded it from OTN). It looks like the java code for "public class myPLSQLIndexTab" might be a java stored procedure stored in the oracle database?
Pardon my ignorance because I've never worked on java code in the oracle database itself but how would I call such a program outside the oracle database? For example say I have a batch job that downloads data from a webservice and that batch job is written in java and its sitting on a batch server somewhere on the network. But the java program that inserts data into the database is sitting in the oracle database (also somewhere in the same network). How can the java code sitting on the batch server talk to the java code sitting on the oracle server? Is it the same as calling a pl/sql package using CallableStatement?
Thanks
Alex -
Connecting to Mainframe datacom tables using Java code
Hi,
I want to connect to the mainframe datacom tables using javacode. Can anyone help me out.
Thanks,
Mahesh.I don't have any sample code, but if you have bluetooth software on your computer, you can setup the serial port profile between your computer and cellphone, and treat your cellphone as a normal modem.
You can then look at the javacomms api, which should help you.
http://java.sun.com/products/javacomm/ -
Error while Shell executing from Oracle Using java proc
Hi All,
After a long time I'm here again.
I'm facing one strange problem.
SQL>
SQL> select * from v$version;
BANNER
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for Linux: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
Elapsed: 00:00:00.01
SQL>
SQL>And, the purpose of this procedure is to execute shell command from PL/SQL application.
It seems that this procedure is able to execute shell commands like *'pwd'*.
But, when it comes to other commands like *'ls -lrt'* or *'sqlldr'* it throws error.
Kindly find the following details -
SQL> declare
2 err_cd number;
3 err_desc varchar2(500);
4 begin
5 dbms_java.set_output(1000000);
6 host(p_command => '/a/mis/Sqlloader_script/loader_command/ST_det.sh');
7 dbms_output.put_line('Successfully Executed SQL Loader Command');
8 exception
9 when others then
10 err_cd := 1;
11 err_desc := substr(sqlerrm,1,500);
12 dbms_output.put_line(err_desc);
13 end;
14 /
Process err :/a/mis/Sqlloader_script/loader_command/ST_det.sh: line 19: sqlldr: No such file or directory
Successfully Executed SQL Loader Command
PL/SQL procedure successfully completed.
Elapsed: 00:00:00.11
SQL>
SQL> declare
2 err_cd number;
3 err_desc varchar2(500);
4 begin
5 dbms_java.set_output(1000000);
6 host(p_command => 'pwd');
7 dbms_output.put_line('Successfully Executed SQL Loader Command');
8 exception
9 when others then
10 err_cd := 1;
11 err_desc := substr(sqlerrm,1,500);
12 dbms_output.put_line(err_desc);
13 end;
14 /
Process out :/home/oracle/app/oracle/product/11.2.0/dbhome_1/dbs
Successfully Executed SQL Loader Command
PL/SQL procedure successfully completed.
Elapsed: 00:00:00.11
SQL>But, the file exists in the following path -
SQL> !ls -lrt /a/mis/Sqlloader_script/loader_command/ST_det.sh
-rwxrwxr-x 1 oracle root 1315 Apr 13 13:40 /a/mis/Sqlloader_script/loader_command/ST_det.shAny idea?
Where is the privileges that i need to give to the current user?
When i directly execute the Sql Loader from the oracle o/s - it ran successfully.
[oracle@pult loader_command]$ /a/mis/Sqlloader_script/loader_command/ST_det.sh
SQL*Loader: Release 11.2.0.1.0 - Production on Fri Apr 13 14:59:19 2012
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
Commit point reached - logical record count 64
Commit point reached - logical record count 128
Commit point reached - logical record count 192
Commit point reached - logical record count 256
Commit point reached - logical record count 320
Commit point reached - logical record count 384
Commit point reached - logical record count 448
Commit point reached - logical record count 512
Commit point reached - logical record count 576
Commit point reached - logical record count 640
Commit point reached - logical record count 704
Commit point reached - logical record count 732
Succesful execution of Loading.
[oracle@pult loader_command]$
[oracle@pult loader_command]$Thanks in advance.This is a generic java proc.
It works well with windows.
But, facing this problem in Linux.
Procedure looks like -
create or replace and compile java source named host as
import java.io.*;
public class Host {
public static void executeCommand(String command) {
try {
String[] finalCommand;
if (isWindows()) {
finalCommand = new String[4];
finalCommand[0] = "C:\\windows\\system32\\cmd.exe"; // Windows XP/2003
finalCommand[1] = "/y";
finalCommand[2] = "/c";
finalCommand[3] = command;
else {
finalCommand = new String[3];
finalCommand[0] = "/bin/bash";
finalCommand[1] = "-c";
finalCommand[2] = command;
final Process pr = Runtime.getRuntime().exec(finalCommand);
pr.waitFor();
new Thread(new Runnable(){
public void run() {
BufferedReader br_in = null;
try {
br_in = new BufferedReader(new InputStreamReader(pr.getInputStream()));
String buff = null;
while ((buff = br_in.readLine()) != null) {
System.out.println("Process out :" + buff);
try {Thread.sleep(100); } catch(Exception e) {}
br_in.close();
catch (IOException ioe) {
System.out.println("Failed to print.");
ioe.printStackTrace();
finally {
try {
br_in.close();
} catch (Exception ex) {}
}).start();
new Thread(new Runnable(){
public void run() {
BufferedReader br_err = null;
try {
br_err = new BufferedReader(new InputStreamReader(pr.getErrorStream()));
String buff = null;
while ((buff = br_err.readLine()) != null) {
System.out.println("Process err :" + buff);
try {Thread.sleep(100); } catch(Exception e) {}
br_err.close();
catch (IOException ioe) {
System.out.println("Process error.");
ioe.printStackTrace();
finally {
try {
br_err.close();
} catch (Exception ex) {}
}).start();
catch (Exception ex) {
System.out.println(ex.getLocalizedMessage());
public static boolean isWindows() {
if (System.getProperty("os.name").toLowerCase().indexOf("windows") != -1)
return true;
else
return false;
};Looking for your reply. -
How to connect to IMAP mail server using java ?
Hello Friends,
I need to include a mailing facility in my application. Now its not the smtp server instead I have to connect to the IMAP server.
Pls provide your valuable suggestions as to how do I go about this ?
What API will I need to download ?? As javamail API does not have IMAP package.
Thank you for your attention.
RegardsWhat API will I need to download ?? As javamail API does not have IMAP package.What gave you that idea? JavaMail does support IMAP.
-
Cannot Connect to Oracle using SSIS
I am working with a client that has the following: a Windows Server Standard 2003 with SQL Server Standard 2005 installed. Oracle 10g is installed on a Linux Red Hat server. All are 64-bit and have the most current service packs installed. We are trying to pull Oracle data to SQL Server using SSIS and/or the SQL Server Import/Export wizard. the 10g client tools are installed on the Windows/SQL Server box. We can connect from there to Oracle using both SQL *Plus and Aqua Data Studio. However, when I try to import data to SQL Server using with the .Net or OLEDB provider, I get the error stating that I have to install the Oracle client tools.
Can anyone help with this? No one on the Microsoft side seems to have an answer.
Many thanks!
JeanneI am also facing the same problem. I have read a related article on
http://stevemchugh.blogspot.com/2007/02/adventures-of-ssis-and-oracle-in-64bit.html
Although the problem solved in this article is not of exact nature as posted in this post but it still provide some thoughtful inside of SQL server 2006 64 bit and Oracle 10 g SSIS connectivity.
If some succeeds in this please also help in figuring out my problem
Maybe you are looking for
-
ipod touch 4g wont connect to itunes or come out of recovery mode, its just stuck on the connect to itunes screen and will not come out, i tried doing a restore but something happened and now it wont finish or do anything else please help and my itun
-
Error while registering the workflow
Hi all, I am trying to do the Self registration work flow.But while trying to register the work flow i am getting the following error. [echo] ******************************************************************************* [echo] REGISTRATION TOOL [ec
-
Oracle 10g Enterprise manager Solaris 9 (Rman backups)
Hi Guys, I changed the OS and oracle user's password on my database server and OS user on the backup server and since then my rman backups don''t run. What could be the reason because when I click on the Disk Test Backup it says I must supply the Hos
-
How to create a New Screen Variant
Dear Friends, I would like to know as our client requires in MIRO transaction GRN details comes in last column as per standard format. We want to bring the same at no 3 position. How to go about it and what are the steps to be followed for the same.
-
Alternate correspondance address for vendor
Dear experts , How can i maintain an alternate a correspondence address in vendor master . I have a vendor for whom the billing address & correspondence addresses are different . Regards , Anis