Rmi Database communication(Please help)
sir
i am trying to return a result set object to a client using rmi.but does not working properly it shows number of exception.but connection is established through it.
here is the coding of Implementation class.plese give me asolution as early as posssible
IMPLEMENTATION CLASS
import java.rmi.*;
import java.rmi.server.*;
import java.io.*;
import java.sql.*;
public class scmimpl extends UnicastRemoteObject implements scmintf,Serializable
private ResultSet rs=null;
ResultSet rs1=null;
ObjectOutputStream os;
private Statement st=null;
private Connection con=null;
public scmimpl() throws RemoteException,IOException
public boolean Connect() throws RemoteException
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
con=DriverManager.getConnection("jdbc:odbc:mn1","scott","tiger");
con.setAutoCommit(false);
st=con.createStatement();
return true;
}catch(Exception e)
return false;
public ResultSet Quest(String s) throws RemoteException,IOException,NotSerializableException,WriteAbortedException,MarshalException
try{
rs=st.executeQuery(s);
return rs;
catch(Exception e)
System.out.println("error---->"+e);
return rs=null;
public boolean Close()
try{
rs1.close();
}catch(Exception ex){}
return(true);
public int Update(String s)
int bl=0;
try{
bl=st.executeUpdate(s);
catch(Exception ex)
{System.out.println(""+ex);}
return bl;
public boolean Cancel()
try{
con.rollback();
return true;
catch(Exception e){return false;}
public boolean Submit()
try{
con.commit();
return true;
catch(Exception e){return false;}
INTERFACE CLASS
import java.rmi.*;
import java.sql.*;
import java.io.*;
public interface scmintf extends Remote
boolean Connect() throws RemoteException,IOException;
ResultSet Quest(String s) throws RemoteException,IOException,WriteAbortedException,WriteAbortedException;
int Update(String s1) throws RemoteException;
boolean Close() throws RemoteException;
boolean Cancel() throws RemoteException;
boolean Submit() throws RemoteException;
SERVER PROGRAM
import java.rmi.*;
import java.net.*;
public class scmServer
public static void main(String arg[])
try
scmimpl SCMimpl=new scmimpl();
Naming.rebind("scmServer",SCMimpl);
catch(Exception e)
CLIENT PROGRAM
import java.rmi.*;
import java.sql.*;
import java.io.*;
public class client implements Serializable
public static void main(String arg[])
try
String URL="rmi://localhost/scmServer";
scmintf SCMintf=(scmintf)Naming.lookup(URL);
boolean f=SCMintf.Connect();
System.out.println(""+f);
// int n=SCMintf.Update("insert into blogin values('naveen','naveen','a')");
// System.out.println(""+n);
//boolean f1=SCMintf.Submit();
ResultSet rs1=SCMintf.Quest("select username from blogin where username='naveen'");
//FileInputStream is =new FileInputStream("c:/Sale/Working/scmClient/t.tmp");
//ObjectInputStream p=new ObjectInputStream(is);
//rs1=(ResultSet)p.readObject();
//is.close();
// os.readObject();
}catch(Exception e){
System.out.println(e);
e.printStackTrace();
sir these are the exception shown by the program
EXCEPTION
java.rmi.UnmarshalException: error unmarshalling return; nested exception is: java.io.WriteAbortedException: Writing aborted by exception; java.io.NotSerializableException: sun.jdbc.odbc.JdbcOdbcResultSetjava.rmi.UnmarshalException: error unmarshalling return; nested exception is: java.io.WriteAbortedException: Writing aborted by exception; java.io.NotSerializableException: sun.jdbc.odbc.JdbcOdbcResultSetjava.io.WriteAbortedException: Writing aborted by exception; java.io.NotSerializableException: sun.jdbc.odbc.JdbcOdbcResultSet at java.lang.Throwable.<init>(Throwable.java:96) at java.lang.Exception.<init>(Exception.java:44) at java.io.IOException.<init>(IOException.java:49) at java.io.ObjectStreamException.<init>(ObjectStreamException.java:31) at java.io.WriteAbortedException.<init>(WriteAbortedException.java:45) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:451) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:242) at sun.rmi.server.UnicastRef.unmarshalValue(UnicastRef.java:304) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:138) at scmimpl_Stub.Quest(Unknown Source) at client.main(client.java:15)Process Exit...
thanking you
I think the exception output held your answers:
java.io.WriteAbortedException: Writing aborted by exception;
... and ...
java.io.NotSerializableException: sun.jdbc.odbc.JdbcOdbcResultSet
Anything passed accross the network through RMI must be serializable ..and a ResultSet is not.
Try 'micro-managing' the results on the server side ...if that makes sense to you. Another alternative that I have tried (with ok results) is returning a two dimensional Object array ie: Object[][] that represents the ResultSet. Actually, I found that it works great.
public static class MovieCapsule implements java.io.Serializable {
public int mode;
public Object[] data;
/** MovieCapsule <I>default</I> Constructor */
public MovieCapsule() {
mode = -1;
data = null;
/** MovieCapsule <I>loaded</I> Constructor
* @param md Sets the 'mode' integer.
* @param dta Sets the Object[] data within the MovieCapsule.
public MovieCapsule(int md, Object[] dta) {
mode = md;
data = dta;
}This actually was used for a single row of results, but you get the idea. I've worked with a 2D array as well.
Similar Messages
-
How to use a vector to navigate my database? please help me.. ty
how to use a vector to navigate my database? please help me.. ty
Quite unclear request�
Can you provide more details? -
Not able drop a user in database.. please help
Not able drop a user in database.. please help
SQL> drop user xxx cascade;
drop user xxx cascade
ERROR at line 1:
ORA-00600: internal error code, arguments: [16500], [kqdcru], [D], [2], [74],
[BIN$gwB1YtUSNkHgQKjAVbQi5w==$0], [], []
i tried to clear recycle bin .. it went fine as sysdba but not an user
As sys:
purge recyclebin;
Recyclebin purged.
SQL> conn xxx
Enter password:
Connected.
SQL> purge recyclebin;
purge recyclebin
ERROR at line 1:
ORA-00600: internal error code, arguments: [16500], [kqdcru], [D], [2], [74],
[BIN$gwB1YtUSNkHgQKjAVbQi5w==$0], [], []
restart of db not helping out...
thanks in advance.. help me out..You didn't mention your Database and O/S details....
drop user xxx cascade
ERROR at line 1:
ORA-00600: internal error code, arguments: [16500], [kqdcru], [D], [2], [74],
[BIN$gwB1YtUSNkHgQKjAVbQi5w==$0], [], []
SQL> purge recyclebin;
purge recyclebin
ERROR at line 1:
ORA-00600: internal error code, arguments: [16500], [kqdcru], [D], [2], [74],
[BIN$gwB1YtUSNkHgQKjAVbQi5w==$0], [], []You should probably raise a Service Request for ORA-00600 errors, as Oracle Support needs to look at it.
Regards
Z.K. -
Problem in socket communication please help me!
server
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.io.*;
import java.net.*;
class SocketServer extends JFrame
implements ActionListener {
JLabel text1, text2;
JButton button1, button2;
JPanel panel;
JTextField textField1, textField2;
ServerSocket server = null;
Socket socket = null;
BufferedReader in1 = null;
PrintWriter out1 = null;
String line1;
String line2;
SocketServer(){ //Begin Constructor
text1 = new JLabel("Send Information:");
text2 = new JLabel("Receive Information:");
textField1 = new JTextField(20);
textField2 = new JTextField(20);
button1 = new JButton("Send");
button2 = new JButton("Receive");
button1.addActionListener(this);
button2.addActionListener(this);
panel = new JPanel();
panel.setLayout(new GridLayout(2,3));
panel.setBackground(Color.lightGray);
getContentPane().add(panel);
panel.add(text1);
panel.add(textField1);
panel.add(button1);
panel.add(text2);
panel.add(textField2);
panel.add(button2);
setSize(500,100);
} //End Constructor
public void actionPerformed(ActionEvent event) {
Object source = event.getSource();
if(source == button1){
//Send data over socket
String text = textField1.getText();
out1.println(text);
textField1.setText(new String(""));
//Receive text from server
try{
String line1 = in1.readLine();
System.out.println("Text received :" + line1);
} catch (IOException e){
System.out.println("Read failed");
System.exit(1);
if(source == button2){
textField2.setText(line2);
public void listenSocket(){
try{
server = new ServerSocket(4444);
} catch (IOException e) {
System.out.println("Could not listen on port 4444");
System.exit(-1);
try{
socket = server.accept();
} catch (IOException e) {
System.out.println("Accept failed: 4444");
System.exit(-1);
try{
in1 = new BufferedReader(new InputStreamReader(socket.getInputStream()));
out1 = new PrintWriter(socket.getOutputStream(), true);
} catch (IOException e) {
System.out.println("Accept failed: 4444");
System.exit(-1);
while(true){
try{
line2 = in1.readLine();
//Send data back to client
out1.println(line2);
} catch (IOException e) {
System.out.println("Read failed");
System.exit(-1);
protected void finalize(){
//Clean up
try{
in1.close();
out1.close();
server.close();
} catch (IOException e) {
System.out.println("Could not close.");
System.exit(-1);
public static void main(String[] args){
SocketServer frame = new SocketServer();
frame.setTitle("Chat (Server)");
WindowListener l = new WindowAdapter() {
public void windowClosing(WindowEvent e) {
System.exit(0);
frame.addWindowListener(l);
frame.pack();
frame.setVisible(true);
frame.listenSocket();
client
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import java.io.*;
import java.net.*;
class SocketClient extends JFrame
implements ActionListener {
JLabel text1, text2;
JButton button1, button2;
JPanel panel;
JTextField textField1, textField2;
Socket socket = null;
PrintWriter out = null;
BufferedReader in = null;
String line3;
String line4;
SocketClient(){ //Begin Constructor
text1 = new JLabel("Send Information:");
text2 = new JLabel("Receive Information:");
textField1 = new JTextField(20);
textField2 = new JTextField(20);
button1 = new JButton("Send");
button2 = new JButton("Receive");
button1.addActionListener(this);
button2.addActionListener(this);
panel = new JPanel();
panel.setLayout(new GridLayout(2,3));
panel.setBackground(Color.lightGray);
getContentPane().add(panel);
panel.add(text1);
panel.add(textField1);
panel.add(button1);
panel.add(text2);
panel.add(textField2);
panel.add(button2);
setSize(500,100);
} //End Constructor
public void actionPerformed(ActionEvent event){
Object source = event.getSource();
if(source == button1){
//Send data over socket
String text = textField1.getText();
out.println(text);
textField1.setText(new String(""));
//Receive text from server
try{
String line3 = in.readLine();
System.out.println("Text received :" + line3);
} catch (IOException e){
System.out.println("Read failed");
System.exit(1);
if(source == button2){
textField2.setText(line4);
public void listenSocket(){
//Create socket connection
try{
socket = new Socket("Localhost", 4444);
out = new PrintWriter(socket.getOutputStream(), true);
in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
} catch (UnknownHostException e) {
System.out.println("Unknown host: Localhost");
System.exit(1);
} catch (IOException e) {
System.out.println("No I/O");
System.exit(1);
while(true){
try{
line4 = in.readLine();
//Send data back to client
out.println(line4);
} catch (IOException e) {
System.out.println("Read failed");
System.exit(-1);
public static void main(String[] args){
SocketClient frame = new SocketClient();
frame.setTitle("Chat (Client)");
WindowListener l = new WindowAdapter() {
public void windowClosing(WindowEvent e) {
System.exit(0);
frame.addWindowListener(l);
frame.pack();
frame.setVisible(true);
frame.listenSocket();
There were problems when executing the application
please help mei had no problem running this... make sure you open the server part first and have that sitting and waiting for the client to connect.... then it should work.
Would you believe that i too am working on the server / socket thing... however my problem is getting the server to read from a database and report back to the client.... -
Multiple database operations in Database Adapter - please help
Hi,
I would like to have multiple operation in my database adapter. I drop the database adapter onto the composite.xml and follow the wizard. An adapter with one operation is created.
When I click the "Edit" button on it and run the wizard again, all the previous changes are lost, and only the new operation is present.
In the "Oracle® Fusion Middleware User's Guide for Technology Adapters 11g Release 1 (11.1.1.5.0) 9 Oracle JCA Adapter for Database" I read the following:+
While at run time you have Oracle Database Adapter instances, at design time you have the Adapter Configuration Wizard (link). You can run it once to generate a single adapter service end point, and then multiple times in edit mode to make incremental changes to each. It generates all the adapter related artifacts needed when deploying a SOA composite as Table 9-1 lists.
But I how do I change the Jdeveloper into the "edit mode" ??? I've been trying for hours, and I cant figure it out. Please help!!!Hi Vijay,
did you actually test this? When I finish creating a DBAdapter, there is a operation present. Then when I click edit again on the DBAdapter, and I create another select, when I finish only the first operation is gone, and I can only see the one I've created via the last edit.
I dont understand your reply. Can I have two operations, each one with select underneath, in the same adapter?
Edited by: user13604541 on Jan 30, 2012 11:19 AM -
Problems with Servlet to JSP communication please help!!!
Hello All ,
we have different web applications running
e.g.
We have 2 webApp named A and B are running and there URL are
http://localhost:8080/A and
http://localhost:8080/B
and we have one common WebApp running at
http://localhost:8080/common
Our problem is that whenever a user log in to the system he/she will first call the
common URL and then enter his user name and password
and depending on his username we have redirect user to either A or B with his pasword and username as parameter to the request.
i.e. in common module whenever i get userName and password we call a Servlet to authenticate the user and to detemine which webapp to forward to..
i have to call jsp accordingly from servlet in common webApp to JSP in different webapp.
I m wonderning how it is possilble.
As
i don't know how to call another webApp using
RequestDispatcher.forward () method and
also
i am not able to set paramters with the request whenever i user response.sendRedirect() method
I am wondering what could be the way to pass paramer to the request from servlet in one webApp to JSP in another webApp
Please help its urgent!!!
thankx in advanceforward() can't call another webapp.
There are several ways you could do this.
1) Share the session object across both webapps and set something as an attribute of the session.
2) Use a database or file storage to record the transaction, then go to the second webapp, which picks up that info. -
Hey I done my database code through JCreator but it did not seemed to work. This is the buy ticket page whereby you buy the movie ticket online that i am creating.
The java file is called BuyTextBox.java with database by microsoft access called buy.db .
I will want the information that the user entered saved be stored in the database. I tried but it did not seemed to work!
Here is the code:
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import javax.swing.border.*;
import java.io.*;
import java.util.*;
import java.sql.*;
public class BuyTextBox extends JPanel implements ActionListener {
//Instance Variables
private String FirstName = "fn";
private String LastName = "ln";
private String Address = "addr";
private String ContactNumber ="1234567";
private String CreditCardNumber ="111111";
private String Email="[email protected]";
private int NumberTickets;
public String getFirstName(){
return FirstName;
public String getLastName(){
return LastName;
public String getAddress(){
return Address;
public String getContactNumber(){
return ContactNumber;
public String getCreditCardNumber(){
return CreditCardNumber;
public String getEmail(){
return Email;
public int getNumberTickets(){
return NumberTickets;
private JLabel movieLabel = new JLabel("Select movie ticket:");
private JLabel blankLabel = new JLabel(" ");
private JLabel blank2Label = new JLabel(" ");
private JLabel blank3Label = new JLabel(" ");
private JLabel blank4Label = new JLabel(" ");
private JLabel blank5Label = new JLabel(" ");
private JLabel FirstNameLabel = new JLabel("First Name:");
private JTextField FirstNameTextField = new JTextField();
private JLabel LastNameLabel = new JLabel("Last Name:");
private JTextField LastNameTextField = new JTextField();
private JLabel AddressLabel = new JLabel("Address:");
private JTextArea AddressTextArea = new JTextArea();
private JLabel contactLabel = new JLabel("Contact number:");
private JTextField ContactNumberTextField = new JTextField();
private JLabel creditLabel = new JLabel("Credit card number:");
private JTextField CreditCardNumberTextField = new JTextField();
private JLabel emailLabel = new JLabel("Email:");
private JTextField EmailTextField = new JTextField();
private JLabel numberLabel = new JLabel("Enter number of tickets:");
private JTextField NumberTextField = new JTextField();
private JButton saveButton;
private JButton resetButton;
public BuyTextBox() {
JPanel inputPanel=new JPanel();
inputPanel.setBorder(new TitledBorder("Please enter your informations:"));
inputPanel.setLayout(new GridLayout(0,4,40,40));
inputPanel.add(FirstNameLabel);
inputPanel.add(FirstNameTextField);
inputPanel.add(LastNameLabel);
inputPanel.add(LastNameTextField);
inputPanel.add(AddressLabel);
inputPanel.add(AddressTextArea);
inputPanel.add(contactLabel);
inputPanel.add(ContactNumberTextField);
inputPanel.add(creditLabel);
inputPanel.add(CreditCardNumberTextField);
inputPanel.add(emailLabel);
inputPanel.add(EmailTextField);
inputPanel.add(movieLabel);
inputPanel.add(new Checkbox("Chicken Little"));
inputPanel.add(new Checkbox("King Kong"));
inputPanel.add(new Checkbox("Elizabeth Town"));
inputPanel.add(blankLabel);
inputPanel.add(new Checkbox("Curse Of Were Rabbit"));
inputPanel.add(new Checkbox("Derailed"));
inputPanel.add(new Checkbox("In Her Shoes"));
inputPanel.add(new Checkbox("Proved"));
inputPanel.add(new Checkbox("Family Stone"));
inputPanel.add(new Checkbox("TinMine"));
inputPanel.add(new Checkbox("Narnia"));
inputPanel.add(blank2Label);
inputPanel.add(numberLabel);
inputPanel.add(NumberTextField);
JPanel confirmPanel=new JPanel();
saveButton=new JButton("Save");
resetButton=new JButton("Reset");
confirmPanel.add(saveButton);
confirmPanel.add(resetButton);
setLayout(new BorderLayout());
add(inputPanel, BorderLayout.PAGE_START);
add(confirmPanel, BorderLayout.PAGE_END);
resetButton.addActionListener(this);
saveButton.addActionListener(this);
public void actionPerformed(ActionEvent e) {
if (e.getSource() == resetButton)
resetButtonClicked();
else if (e.getSource() == saveButton)
saveButtonClicked();
public BuyTextBox(String aName){
name = aName;
public boolean insertDetails(){
boolean success = false;
DBController db = new DBController();
// buy db = new buy();
db.setUp("buy");
String sql = "INSERT INTO buy(FirstName,LastName, Address,ContactNumber,CreditCardNumber,Email,NumberTickets)";
sql += "values("+FirstName+", '"+LastName+"', "+Address+"', "+ContactNumber+
"', "+CreditCardNumber+"', "+Email+"', "+NumberTickets+");";
db.updateRequest(sql);
db.terminate();
success = true;
return success;
private void resetButtonClicked()
FirstNameTextField.setText("");
private void saveButtonClicked()
FirstName = FirstNameTextField.getText().trim();
LastName = LastNameTextField.getText().trim();
Address = AddressTextArea.getText().trim();
ContactNumber = ContactNumberTextField.getText().trim();
CreditCardNumber = CreditCardNumberTextField.getText().trim();
Email = EmailTextField.getText().trim();
NumberTickets = NumberTextField.getText().trim();
if (FirstName.length() == 0)
JOptionPane.showMessageDialog(this ," Name cannot be blank" , "Invalid Field", JOptionPane.ERROR_MESSAGE);
else
JOptionPane.showMessageDialog(this, "Record added.", "Confirmation", JOptionPane.INFORMATION_MESSAGE);
if (insertDetails())
System.out.println("DB Update OK");
else
System.out.println("DB Update Failed");
public static void main(String args[]) {
JFrame app=new JFrame();
//Container contentPane = getContentPane ();
BuyTextBox p=new BuyTextBox();
app.getContentPane().add(p);
app.setTitle ("Buy tickets ");
app.setSize(1050,740);
app.setBackground (new Color(0,160,198));
app.setResizable (false);
app.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
app.setVisible(true);
If you know whats wrong with the code, please teach me what to do to make my databse successful!and now that one try to hack my icound but i set password so strong cuz it associat me just i little bit you will check me cuz i have your product all i used to use my username nerdseery but ha hacked me all every email addrese i used username nerdsery but now i must changed to nerrdsurery
-
Error while running adcfgclone on database tier please help me
Hello
I am doing cloning through cold backup and i face some errors..here is my logfile.....please suggest me some solution...
Executing script in InstantiateFile:
Attempting to create a back up of the Context file
Created back up file of name :
/home/clone/db/db/tech_st/10.2.0/appsutil/out/CLONE_zishan/12071920/CLONE_zishan.xml
===========================================================================
Starting synchronization of file system Context file and its templates with those in the database
Database connection : Failed
OAM Context editing support feature: Unverified
OAM Customization support feature : Unverified
File system template : /home/clone/db/db/tech_st/10.2.0/appsutil/template/adxdbctx.tmp
Checking for customizations to Context template
Warning: Unable to connect to Database.
If the system is OAM enabled, this may result in loss of customizations.
Looking for custom template at : /home/clone/db/db/tech_st/10.2.0/appsutil/template/custom/adxdbctx.tmp
Custom template : Not available
Customizations found : None
File system Context file :/home/clone/db/db/tech_st/10.2.0/appsutil/CLONE_zishan.xml
Checking the Context file for possible updates from the Database
Warning: Unable to connect to Database.
If the system is OAM enabled, this may result in loss of customizations and the Context files in DataBase and in the file system may be unsynchronized
===========================================================================
Starting Updates of Context file Tue Dec 07 19:20:41 GMT+05:30 2010
found context version : 120.27
available update version : 120.27
No updates to apply
Ending Updates of Context file
===========================================================================
===========================================================================
Starting Context Value Management System at Tue Dec 07 19:20:41 GMT+05:30 2010
Using version 120.8
Options:
Force : no
Contextfile : /home/clone/db/db/tech_st/10.2.0/appsutil/CLONE_zishan.xml
Templatefile : /home/clone/db/db/tech_st/10.2.0/appsutil/template/adxdbctx.tmp
ValueUpdateFile : /home/clone/db/db/tech_st/10.2.0/appsutil/template/adcvmdb.xml
Verifying value management system requirements:
ContextFile : VALID
Template File : VALID
ValueUpdateFile : VALID
Parsing the ValueUpdateFile
[ s_contextfile ]
Action : seed
Change reason : Setting the location to what has been specified by user
New value : /home/clone/db/db/tech_st/10.2.0/appsutil/CLONE_zishan.xml
===========================================================================
[ Config tool : /home/clone/db/db/tech_st/10.2.0/appsutil/bin/adgentns.pl ]
Command : /home/clone/db/db/tech_st/10.2.0/perl/bin/perl -I /home/clone/db/db/tech_st/10.2.0/perl/lib/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/perl/lib/site_perl/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/appsutil/perl /home/clone/db/db/tech_st/10.2.0/appsutil/bin/adgentns.pl PASSWORD contextfile=/home/clone/db/db/tech_st/10.2.0/appsutil/CLONE_zishan.xml logdir=/home/clone/db/db/tech_st/10.2.0/appsutil/log/CLONE_zishan
Action : execute
SCRIPT RETURNED:
Generate Tns Names
Classpath : /home/clone/db/db/tech_st/10.2.0/jdbc/lib/ojdbc14.jar:/home/clone/db/db/tech_st/10.2.0/appsutil/java/xmlparserv2.jar:/home/clone/db/db/tech_st/10.2.0/appsutil/java:/home/clone/db/db/tech_st/10.2.0/jlib/netcfg.jar:/home/clone/db/db/tech_st/10.2.0/jlib/ldapjclnt10.jar
Loading ORACLE_HOME environment from /home/clone/db/db/tech_st/10.2.0
Logfile: /home/clone/db/db/tech_st/10.2.0/appsutil/log/CLONE_zishan/NetServiceHandler.log
Error generating tnsnames.ora from the database, temperory tnsnames.ora will be generated using templates
Instantiating templates
tnsnames.ora instantiated
listener.ora instantiated
adgentns.pl exiting with status 25600
ERRORCODE = 25600 ERRORCODE_END
.end std out.
.end err out.
Result : FAILED
===========================================================================
Ending Context Value Management System.
===========================================================================
===========================================================================
No uploading of Context file and its templates to database. Database conection failed
===========================================================================
Finished running CVM.....
Processing DriverFile = /home/clone/db/db/tech_st/10.2.0/appsutil/template/addbtmpl.drv
AutoConfig Profile Phase
Running Instantiation Drivers for AppsUtil
Looking for the directory : /home/clone/db/db/tech_st/10.2.0/nls/data/9idata
Directory exists
Looking for file : /home/clone/db/db/tech_st/10.2.0/nls/data/old/cr9idata.pl
File exists
Validation complete
ERRORCODE = 0 ERRORCODE_END
.end std out.
.end err out.
AutoConfig Setup Phase
Running Setup Process 2 of 3 for AppsUtil
Executing script in InstantiateFile:
/home/clone/db/db/tech_st/10.2.0/perl/bin/perl -I /home/clone/db/db/tech_st/10.2.0/perl/lib/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/perl/lib/site_perl/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/appsutil/perl /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/txkConfigDbOcm.pl
script returned:
Checking if OCM is already configured in: /home/clone/db/db/tech_st/10.2.0
OCM is not yet configured in: /home/clone/db/db/tech_st/10.2.0
The values for MetaLink ID, CSI and Country Code are not all specified. OCM cannot be configured.
ERRORCODE = 0 ERRORCODE_END
.end std out.
.end err out.
AutoConfig Setup Phase
Running Setup Process 3 of 3 for AppsUtil
Executing script in InstantiateFile:
/home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/afmkinit.sh
script returned:
afmkinit.sh started at Tue Dec 7 19:21:09 IST 2010
The environment settings are as follows ...
ORACLE_HOME : /home/clone/db/db/tech_st/10.2.0
ORACLE_SID : CLONE
TWO_TASK :
PATH : /home/clone/db/db/tech_st/10.2.0/perl/bin:/home/clone/db/db/tech_st/10.2.0/bin:/usr/bin:/usr/sbin:/home/clone/db/db/tech_st/10.2.0/appsutil/jre/bin:/usr/ccs/bin:/bin:/usr/bin/X11:/usr/local/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/usr/lib/qt-3.3/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/oracle1/bin
Library Path : /home/clone/db/db/tech_st/10.2.0/lib:/usr/X11R6/lib:/usr/openwin/lib:/home/clone/db/db/tech_st/10.2.0/lib:/usr/dt/lib:/home/clone/db/db/tech_st/10.2.0/ctx/lib
afmkinit.sh exiting with status 0
.end std out.
.end err out.
Skipping Profile Phase
Skipping Apply Phase
Starting DB listener with command:
/home/clone/db/db/tech_st/10.2.0/appsutil/scripts/CLONE_zishan/addlnctl.sh start CLONE
You are running addlnctl.sh version 120.1
Logfile: /home/clone/db/db/tech_st/10.2.0/appsutil/log/CLONE_zishan/addlnctl.txt
Starting listener process CLONE ...
addlnctl.sh: exiting with status 0
.end std out.
.end err out.
checking DB Connection...
DEBUG: checkDBConnection in()
ADX Database Utility
getConnection() -->
sDbHost : zishan
sDbDomain : mahesh.dba
sDbPort : 1541
sDbSid : CLONE
sDbUser : APPS
Trying to connect using SID...
getConnectionUsingSID() -->
JDBC URL: jdbc:oracle:thin:@zishan.mahesh.dba:1541:CLONE
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE)))
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName.DomainName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Exception occurred: java.sql.SQLException: Listener refused the connection with the following error:
ORA-12514, TNS:listener does not currently know of service requested in connect descriptor
The Connection descriptor used by the client was:
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Connection could not be obtained; returning null
-------------------ADX Database Utility Finished---------------
DEBUG: checkDBConnection out()
Verifying correctness of adcrdbclone.sql
Clustered Database: false
Instantiating /home/clone/db/db/tech_st/10.2.0/appsutil/template/adcrdbclone.sql to /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql.bak
instantiate file:
source : /home/clone/db/db/tech_st/10.2.0/appsutil/template/adcrdbclone.sql
dest : /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql.bak
Instantiating /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql.bak to /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql
instantiate file:
source : /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql.bak
dest : /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/adcrdbclone.sql
Updating:s_db_rollback_segs:(_syssmu1$, syssmu2$, syssmu3$, syssmu4$, syssmu5$, syssmu6$, syssmu7$, syssmu8$, syssmu9$, syssmu10$, syssmu11$, syssmu12$, syssmu13$, syssmu14$, syssmu15$):
Updating:s_undo_tablespace:APPS_UNDOTS1:
Updating:s_database:db102:
Updating:isspfileexists:false:
Updating:s_dbfiles:512:
Executing Configuration Phase...
Deleting files of type INSTALL
Checking for file: /home/clone/db/db/tech_st/10.2.0/network/admin/CLONE_zishan/sqlnet.ora
Processing driver file: /home/clone/db/db/tech_st/10.2.0/appsutil/template/addbtmpl.drv
Checking for file: /home/clone/db/db/tech_st/10.2.0/dbs/initCLONE.ora
File exists
File deleted
Checking for file: /home/clone/db/db/tech_st/10.2.0/network/admin/CLONE_zishan/listener.ora
File exists
File deleted
Checking for file: /home/clone/db/db/tech_st/10.2.0/network/admin/CLONE_zishan/tnsnames.ora
File exists
File deleted
Processing DriverFile = /home/clone/db/db/tech_st/10.2.0/appsutil/template/addbtmpl.drv
AutoConfig Profile Phase
Running Instantiation Drivers for AppsUtil
AutoConfig Setup Phase
Running Setup Process 2 of 3 for AppsUtil
Executing script in InstantiateFile:
/home/clone/db/db/tech_st/10.2.0/perl/bin/perl -I /home/clone/db/db/tech_st/10.2.0/perl/lib/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/perl/lib/site_perl/5.8.3 -I /home/clone/db/db/tech_st/10.2.0/appsutil/perl /home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/txkConfigDbOcm.pl
script returned:
Checking if OCM is already configured in: /home/clone/db/db/tech_st/10.2.0
OCM is not yet configured in: /home/clone/db/db/tech_st/10.2.0
The values for MetaLink ID, CSI and Country Code are not all specified. OCM cannot be configured.
ERRORCODE = 0 ERRORCODE_END
.end std out.
.end err out.
AutoConfig Setup Phase
Running Setup Process 3 of 3 for AppsUtil
Executing script in InstantiateFile:
/home/clone/db/db/tech_st/10.2.0/appsutil/install/CLONE_zishan/afmkinit.sh
script returned:
afmkinit.sh started at Tue Dec 7 19:21:26 IST 2010
The environment settings are as follows ...
ORACLE_HOME : /home/clone/db/db/tech_st/10.2.0
ORACLE_SID : CLONE
TWO_TASK :
PATH : /home/clone/db/db/tech_st/10.2.0/perl/bin:/home/clone/db/db/tech_st/10.2.0/bin:/usr/bin:/usr/sbin:/home/clone/db/db/tech_st/10.2.0/appsutil/jre/bin:/usr/ccs/bin:/bin:/usr/bin/X11:/usr/local/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/usr/lib/qt-3.3/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/oracle1/bin
Library Path : /home/clone/db/db/tech_st/10.2.0/lib:/usr/X11R6/lib:/usr/openwin/lib:/home/clone/db/db/tech_st/10.2.0/lib:/usr/dt/lib:/home/clone/db/db/tech_st/10.2.0/ctx/lib
afmkinit.sh exiting with status 0
.end std out.
.end err out.
Skipping Profile Phase
Skipping Apply Phase
Executing CreateDB...
ADX Database Utility
getConnectionUsingAppsJDBCConnector() -->
APPS_JDBC_URL='null'
Trying to get connection using SID based connect descriptor
getConnection() -->
sDbHost : zishan
sDbDomain : mahesh.dba
sDbPort : 1541
sDbSid : CLONE
sDbUser : APPS
Trying to connect using SID...
getConnectionUsingSID() -->
JDBC URL: jdbc:oracle:thin:@zishan.mahesh.dba:1541:CLONE
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE)))
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName.DomainName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Exception occurred: java.sql.SQLException: Listener refused the connection with the following error:
ORA-12514, TNS:listener does not currently know of service requested in connect descriptor
The Connection descriptor used by the client was:
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Connection could not be obtained; returning null
-------------------ADX Database Utility Finished---------------
adcrdb.sh started at Tue Dec 7 19:21:27 IST 2010
The environment settings are as follows ...
ORACLE_HOME : /home/clone/db/db/tech_st/10.2.0
ORACLE_SID : CLONE
TWO_TASK :
PATH : /home/clone/db/db/tech_st/10.2.0/perl/bin:/home/clone/db/db/tech_st/10.2.0/bin:/usr/bin:/usr/sbin:/home/clone/db/db/tech_st/10.2.0/appsutil/jre/bin:/usr/ccs/bin:/bin:/usr/bin/X11:/usr/local/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/home/clone/db/db/tech_st/10.2.0/appsutil/clone/bin/../jre/bin:/usr/lib/qt-3.3/bin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/oracle1/bin
LD_LIBRARY_PATH : /home/clone/db/db/tech_st/10.2.0/lib:/usr/X11R6/lib:/usr/openwin/lib:/home/clone/db/db/tech_st/10.2.0/lib:/usr/dt/lib:/home/clone/db/db/tech_st/10.2.0/ctx/lib
Executable : /home/clone/db/db/tech_st/10.2.0/bin/sqlplus
The log information will be written to
/home/clone/db/db/tech_st/10.2.0/appsutil/log/CLONE_zishan/adcrdb_CLONE.txt
Creating the control file for CLONE_zishan database ...
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Dec 7 19:21:27 2010
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.
Connected to an idle instance.
ORACLE instance shut down.
Connected to an idle instance.
ORACLE instance started.
Total System Global Area 1073741824 bytes
Fixed Size 1264892 bytes
Variable Size 427819780 bytes
Database Buffers 633339904 bytes
Redo Buffers 11317248 bytes
CREATE CONTROLFILE REUSE SET DATABASE "CLONE"
ERROR at line 1:
ORA-01503: CREATE CONTROLFILE failed
ORA-00200: control file could not be created
ORA-00202: control file: '/home/clone/db/db/apps_st/data/cntrl01.dbf'
ORA-27086: unable to lock file - already in use
Linux Error: 11: Resource temporarily unavailable
Additional information: 8
Additional information: 30389
alter database open resetlogs
ERROR at line 1:
ORA-01507: database not mounted
alter tablespace TEMP1 add tempfile '/home/clone/db/db/apps_st/data/temp01.dbf' REUSE
ERROR at line 1:
ORA-01109: database not open
alter tablespace TEMP2 add tempfile '/home/clone/db/db/apps_st/data/temp02.dbf' REUSE
ERROR at line 1:
ORA-01109: database not open
ALTER DATABASE RENAME GLOBAL_NAME TO "CLONE.mahesh.dba"
ERROR at line 1:
ORA-01109: database not open
ORA-01507: database not mounted
ORACLE instance shut down.
Connected to an idle instance.
ORACLE instance started.
Total System Global Area 1073741824 bytes
Fixed Size 1264892 bytes
Variable Size 427819780 bytes
Database Buffers 633339904 bytes
Redo Buffers 11317248 bytes
ORA-00205: error in identifying control file, check alert log for more info
BEGIN dbms_backup_restore.zeroDbid(0); END;
ERROR at line 1:
ORA-00210: cannot open the specified control file
ORA-06512: at "SYS.X$DBMS_BACKUP_RESTORE", line 4168
ORA-06512: at line 1
ORACLE instance shut down.
Connected to an idle instance.
ORACLE instance started.
Total System Global Area 1073741824 bytes
Fixed Size 1264892 bytes
Variable Size 427819780 bytes
Database Buffers 633339904 bytes
Redo Buffers 11317248 bytes
CREATE CONTROLFILE REUSE SET DATABASE "CLONE"
ERROR at line 1:
ORA-01503: CREATE CONTROLFILE failed
ORA-00200: control file could not be created
ORA-00202: control file: '/home/clone/db/db/apps_st/data/cntrl01.dbf'
ORA-27086: unable to lock file - already in use
Linux Error: 11: Resource temporarily unavailable
Additional information: 8
Additional information: 30389
alter database open resetlogs
ERROR at line 1:
ORA-01507: database not mounted
alter tablespace TEMP1 add tempfile '/home/clone/db/db/apps_st/data/temp01.dbf' REUSE
ERROR at line 1:
ORA-01109: database not open
alter tablespace TEMP2 add tempfile '/home/clone/db/db/apps_st/data/temp02.dbf' REUSE
ERROR at line 1:
ORA-01109: database not open
ALTER DATABASE RENAME GLOBAL_NAME TO "CLONE.mahesh.dba"
ERROR at line 1:
ORA-01109: database not open
Error Running create/replace library with adupdlib.sql
ORA-01109: database not open
PL/SQL procedure successfully completed.
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
exit_code=0
Checking for errors ...
The database has not been successfully created. Shutting down the instance ...
SQL*Plus: Release 10.2.0.2.0 - Production on Tue Dec 7 19:21:33 2010
Copyright (c) 1982, 2005, Oracle. All Rights Reserved.
Connected.
ORACLE instance shut down.
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
.end std out.
.end err out.
ADX Database Utility
getConnectionUsingAppsJDBCConnector() -->
APPS_JDBC_URL='null'
Trying to get connection using SID based connect descriptor
getConnection() -->
sDbHost : zishan
sDbDomain : mahesh.dba
sDbPort : 1541
sDbSid : CLONE
sDbUser : APPS
Trying to connect using SID...
getConnectionUsingSID() -->
JDBC URL: jdbc:oracle:thin:@zishan.mahesh.dba:1541:CLONE
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE)))
Exception occurred: java.sql.SQLException: ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
Trying to connect using SID as ServiceName.DomainName
getConnectionUsingServiceName() -->
JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Exception occurred: java.sql.SQLException: Listener refused the connection with the following error:
ORA-12514, TNS:listener does not currently know of service requested in connect descriptor
The Connection descriptor used by the client was:
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=zishan.mahesh.dba)(PORT=1541))(CONNECT_DATA=(SERVICE_NAME=CLONE.mahesh.dba)))
Connection could not be obtained; returning null
-------------------ADX Database Utility Finished---------------
RC-00118: Error occurred during creation of database
Raised by oracle.apps.ad.clone.ApplyDatabaseHi;
What is EBS and Db,OS?
ERROR at line 1:
ORA-01503: CREATE CONTROLFILE failed
ORA-00200: control file could not be created
ORA-00202: control file: '/home/clone/db/db/apps_st/data/cntrl01.dbf'
ORA-27086: unable to lock file - already in use
Linux Error: 11: Resource temporarily unavailable
Additional information: 8
Additional information: 30389home/clone/db/db/apps_st/data/cntrl01.dbf' This file exsits? If yes you have r/w permission?
alter database open resetlogs
ERROR at line 1:
ORA-01507: database not mounted
alter tablespace TEMP1 add tempfile '/home/clone/db/db/apps_st/data/temp01.dbf' REUSE
ERROR at line 1:
ORA-01109: database not open
alter tablespace TEMP2 add tempfile '/home/clone/db/db/apps_st/data/temp02.dbf' REUSE
*Did you run preclone on source before copy file to target?
Regard
Helios -
Creating a simple and small DataBase..Please HELP
I study Information Systems (MSc)..and I am taking a DataBase course that requires a Project to be done on a RDBMS..I decided to build the database using ORACLE 9i (on windows xp professional)..
I want to use the Database Configuration Assistant to build the Database (easier than to build it manually)..but the Assistant requests from me to input some parameters that are somehow "new and strange" to me as a student..
PLEASE I need the simplest and easiest parameter values to be input to the Assistant that enable me to build a tiny and simple DataBase that is adequete for educational purposes only (small project)..
Also I need to know how to enter the DataBase after I create it..
Thank you very much in advance..I study Information Systems (MSc)..and I am taking a DataBase course that requires a Project to be done on a RDBMS..I decided to build the database using ORACLE 9i (on windows xp professional)..
I want to use the Database Configuration Assistant to build the Database (easier than to build it manually)..but the Assistant requests from me to input some parameters that are somehow "new and strange" to me as a student..
PLEASE I need the simplest and easiest parameter values to be input to the Assistant that enable me to build a tiny and simple DataBase that is adequete for educational purposes only (small project)..
Also I need to know how to enter the DataBase after I create it..
Thank you very much in advance.. -
Problem in reading/writing byte array in Access database! PLEASE HELP!!
Hi,
I want to store a signature, which is in form of a byte array, in OLE Object field in MS Access database. I want then to retrieve this signature and verify it. The problem is that the retrieved byte array is not identical to the stored (original) one, and therefore, verifying the signature fails! Any help would be much appreciated as I can't proceed in my project without solving this problem. Here is the code to do the above mentioned functionality:
//This part stores the signature (VT) in the table TTPTrans
try
{ con = connect();
ps = con.prepareStatement("UPDATE TTPTrans SET VT = ?, SigVT = ? WHERE TransID = ?");
ps.setBinaryStream(1, new ByteArrayInputStream(vt), vt.length);
ps.setBinaryStream(2, new ByteArrayInputStream(sigvt), sigvt.length);
ps.setString(3, tID);
ps.executeUpdate();
ps.close();
con.close();
catch (Exception e)
{ System.err.println(e.getMessage());
e.printStackTrace();
//This part retrive the signature from the table in the byte array o1:
ResultSet result;
byte[] o1 = null;
byte[] o2 = null;
try
{ con = connect();
Statement statement = con.createStatement();
result = statement.executeQuery("SELECT VT, SigVT" +
" FROM TTPTrans" +
" WHERE TransID = " + "'" +
transID + "'");
while (result.next()) {
o1 = result.getBytes("VT");
o2 = result.getBytes("SigVT");
statement.close();
con.close();
catch(Exception e)
{ System.err.println(e.getMessage());
e.printStackTrace();
}In the following code, I use a ASN1SDSSSignature class, which is a subclass that I created from the Siganture class, to create and verify an SDSS signature. The ASN1SDSSSignature has two ASN1Integer class variables:
signcryption = token.getSigncryption();
sig.initVerify(ttpCert);
sig.update(receivedVT);
boolean verified = sig.verify(receivedSigVT);
if(!verified)
System.err.println("TTP signatire on received token invalid. ");
notify()
return;
Where receivedVT and receivedSigVT are the byte arrays retrieved from th database. The following exception is thrown when I run the application:
ASN1 type mismatch!
Expected: codec.asn1.ASN1Integer
In: ASN1SDSSSignature
At index 0
Got tag: 4 and Class: 0
I hope this would clarify the situation and thanks in advance for any comments you may post. -
How to insert data into database. Please help me(Struggling Very much)
Hi i am having a jsp page which contains some textfields and one button. I have a database table and i have added to my page. The first column of Database table is ID which is of NUMERIC type and it has been set into primary key. And rest of fields are CHAR type. I am using SQL Server 2000. I have to enter the data into text fields and when i submit the add button it must add to the database table. But i am getting error like
Exception Details: java.lang.IllegalArgumentException SRNI.TABLE1.NAME
Please i am trying this one from two months. but it is not getting. I have tried alot by studying all tutorials in Java Studio Creator. I have posted many times but i have followed everyones suggestion. Please give me some instances of writing code to the corresponding requirements i have mentioned above.Please explain step by step including simple one also.
Thanking You in Advance.Hi Srinivasan,
Please check out the Database projects available at:
http://blogs.sun.com/sakthi/entry/flavors_of_crud_tutorial_projects
These have been exercised using this tutorial against different databases:
http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/inserts_updates_deletes.html
HTH,
Sakthi -
The FOD schema error our while creating the database. Please help.
I couldn't run the schema for the FOD demo application. when I follow the steps, I get some exception during the database create part.
From the File menu, choose Open. Open the workspace c:\temp\Infrastructure\infrastructure.jws.
( I edited the build.properties with correct values)
In the MasterBuildScript project, select the build.xml file. In the Structure window, right-click the refreshSchema target and choose Run Target "refreshSchema."
refreshSchema:
[sql] Feb 13, 2008 4:44:54 PM oracle.jdbc.driver.OracleDriver registerMBeans
[sql] SEVERE: Found Oracle Apps MBeanServer but the getMBeanServer method threw an exception.
[sql] java.lang.reflect.InvocationTargetException
[sql] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[sql] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[sql] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[sql] at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
[sql] at oracle.jdbc.driver.OracleDriver.registerMBeans(OracleDriver.java:274)
[sql] at oracle.jdbc.driver.OracleDriver$1.run(OracleDriver.java:224)
[sql] at java.security.AccessController.doPrivileged(Native Method)
[sql] at oracle.jdbc.driver.OracleDriver.<clinit>(OracleDriver.java:220)
[sql] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[sql] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[sql] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[sql] at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
[sql] at java.lang.Class.newInstance0(Class.java:350)
[sql] at java.lang.Class.newInstance(Class.java:303)
[sql] at org.apache.tools.ant.taskdefs.JDBCTask.getDriver(JDBCTask.java:364)
[sql] at org.apache.tools.ant.taskdefs.JDBCTask.getConnection(JDBCTask.java:304)
[sql] at org.apache.tools.ant.taskdefs.SQLExec.execute(SQLExec.java:346)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:64)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:378)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:64)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:378)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.Target.execute(Target.java:341)
[sql] at org.apache.tools.ant.Target.performTasks(Target.java:369)
[sql] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
[sql] at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:37)
[sql] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
[sql] at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
[sql] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
[sql] at org.apache.tools.ant.Task.perform(Task.java:364)
[sql] at org.apache.tools.ant.Target.execute(Target.java:341)
[sql] at org.apache.tools.ant.Target.performTasks(Target.java:369)
[sql] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
[sql] at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
[sql] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40)
[sql] at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
[sql] at org.apache.tools.ant.Main.runBuild(Main.java:668)
[sql] at org.apache.tools.ant.Main.startAnt(Main.java:187)
[sql] at org.apache.tools.ant.Main.start(Main.java:150)
[sql] at org.apache.tools.ant.Main.main(Main.java:240)
[sql] Caused by: java.lang.ClassNotFoundException: oracle.as.jmx.framework.standardmbeans.spi.JMXFrameworkProviderImpl
[sql] at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
[sql] at java.security.AccessController.doPrivileged(Native Method)
[sql] at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
[sql] at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
[sql] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
[sql] at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
[sql] at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
[sql] at java.lang.Class.forName0(Native Method)
[sql] at java.lang.Class.forName(Class.java:242)
[sql] at oracle.as.jmx.framework.PortableMBeanFactory.init(PortableMBeanFactory.java:1687)
[sql] at oracle.as.jmx.framework.PortableMBeanFactory.<init>(PortableMBeanFactory.java:156)
[sql] at oracle.as.jmx.framework.PortableMBeanFactory.<init>(PortableMBeanFactory.java:164)
[sql] ... 49 more
[sql] Executing file: C:\temp\Infrastructure\DBSchema\Scripts\SQLRunner56601127.sql
[sql] 11 of 11 SQL statements executed successfullyHi,
I see the same exceptios, but the schema installs successfully. Have a look at the end of the log window. It should state that the schema was created successfully.
Frank -
Display '0s' for null database items Please help!
Hi all,
I need your help on a possible minor problem I'm encountering. I have 5 fields (all numeric data types) on my form of which, the last field is a sum (formula non-database item) of the top four items. 2 out of the remaining 4 fields are database text items in which I'd like to update the database based on user input. The table that stores the 4 values does not require data and defaults to null if no data present.
What I'd like to do is display a '0' on the form so that its visible and it could get added to the formula sum item but not update the database fields with a '0' (if any one of those top 4 fields returns null from the table ). I've tried creating a formula in the property palette on the fields with an nvl(field,0) function and got a chain reference error that I couldn't figure out based on the oracle error suggestions. Does anyone have any suggestions on how I could handle my request. Any help would be greatly appreciated.
Thanks,
EricZakiy,
I don't know much about the POST-CHANGE trigger. Did a little research and posted some code in there retrieving the nvl(field) value. It compiled ok but didn't display the '0.' I'm not sure if I used the trigger the right way.
Here's my code:
DECLARE
v_points NUMBER;
CURSOR c_points IS
(SELECT nvl(points,0)
FROM student
WHERE student_id = :id);
BEGIN
OPEN c_points;
FETCH c_points INTO v_points;
CLOSE c_points;
END;
If this is incorrect, do you have an example from what you were thinking? Also, just out of curiosity, why do you recommend this trigger over the formula?
From what I was mentioning before, I don't know why the formula w/the nvl works in the sum field but doesn't in the other 4 fields. The sum field is a non-database item whereas 2 others are display items and the remaining 2 are text items. Seems simple enough to use the nvl in the formula section for all 4 fields I kept getting that error.
Eric -
Hello everyone :
I can't switchover to primary. following is error and information.
RHEL 6.3 x86-64
Oracle database 11.2.0.3.0 Enterprise edition
Primary database = orclprmy
Standby database = orclstby1
##### /etc/hosts on orclstby1
[root@orclstby1 admin]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.50.211 ttprmy
192.168.50.212 orclstby1
### DG broker error
DGMGRL for Linux: Version 11.2.0.3.0 - 64bit Production
Copyright (c) 2000, 2009, Oracle. All rights reserved.
Welcome to DGMGRL, type "help" for information.
Connected.
DGMGRL> show configuration;
Configuration - TTDGConfig1
Protection Mode: MaxPerformance
Databases:
orclstby1 - Primary database
Error: ORA-16778: redo transport error for one or more databases
orclprmy - Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
ERROR
DGMGRL>
########### listener.ora on orclstby1
[root@orclstby1 admin]# cat listener.ora
# listener.ora Network Configuration File: /u2/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = orclstby1)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME=orcl)
(SID_NAME = orclstby1)
(ORACLE_HOME = /u2/oracle/product/11.2.0/dbhome_1)
(SID_DESC =
(GLOBAL_DBNAME=orclstby1)
(SID_NAME = orclstby1)
(ORACLE_HOME = /u2/oracle/product/11.2.0/dbhome_1)
(SID_DESC =
(GLOBAL_DBNAME=orclstby1_DGMGRL)
(SID_NAME = orclstby1)
(ORACLE_HOME = /u2/oracle/product/11.2.0/dbhome_1)
ADR_BASE_LISTENER = /u2/oracle
############## tnsnames.ora on orclstby1
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.50.212)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED)(SERVICE_NAME = orcl))
orclprmy =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.50.211)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED)(SERVICE_NAME = orclprmy))
orclprmy_DGMGRL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.50.211)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED)(SERVICE_NAME = orclprmy_DGMGRL))
orclstby1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.50.212)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED)(SERVICE_NAME = orclstby1))
orclstby1_DGMGRL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.50.212)(PORT = 1521))
(CONNECT_DATA = (SERVER = DEDICATED)(SERVICE_NAME = orclstby1_DGMGRL))
##### alert log on orclstby1.
Fatal NI connect error 12504, connecting to:
(DESCRIPTION=(CONNECT_DATA=(SERVICE_NAME=)(CID=(PROGRAM=oracle)(HOST=orclstby1)(USER=oracle)))(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.50.211)(PORT=1521)))
VERSION INFORMATION:
TNS for Linux: Version 11.2.0.3.0 - Production
TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.3.0 - Production
Time: 06-SEP-2013 13:19:55
Tracing not turned on.
Tns error struct:
ns main err code: 12564
TNS-12564: TNS:connection refused
ns secondary err code: 0
nt main err code: 0
nt secondary err code: 0
nt OS err code: 0
There is problem in alert log.
In the /etc/hosts file. The standby server (orclstby1) ip is 192.168.50.212. but alert log is 192.168.50.211.
Is any idea?
Thanks for help.
消息编辑者为:user4914135#### on primary database
SQL> select dest_name,status,target,archiver,schedule, valid_type,valid_role,db_unique_name,error from v$archive_dest;
DEST_NAME STATUS TARGET ARCHIVER SCHEDULE VALID_TYPE VALID_ROLE DB_UNIQUE_NAME
ERROR
LOG_ARCHIVE_DEST_1 VALID LOCAL ARCH ACTIVE ALL_LOGFILES ALL_ROLES orclprmy
LOG_ARCHIVE_DEST_2 VALID REMOTE LGWR PENDING ALL_LOGFILES PRIMARY_ROLE orclstby1
LOG_ARCHIVE_DEST_3 INACTIVE LOCAL ARCH INACTIVE ALL_LOGFILES ALL_ROLES NONE
#### on standby database
SQL> select dest_name,status,target,archiver,schedule, valid_type,valid_role,db_unique_name,error from v$archive_dest;
DEST_NAME STATUS TARGET ARCHIVER SCHEDULE VALID_TYPE VALID_ROLE DB_UNIQUE_NAME
ERROR
LOG_ARCHIVE_DEST_1 VALID PRIMARY ARCH ACTIVE ALL_LOGFILES ALL_ROLES orclstby1
LOG_ARCHIVE_DEST_2 ERROR STANDBY LGWR PENDING ONLINE_LOGFILE PRIMARY_ROLE orclprmy
ORA-12504: TNS:listener was not given the SERVICE_NAME in
CONNECT_DATA
LOG_ARCHIVE_DEST_3 INACTIVE PRIMARY ARCH INACTIVE ALL_LOGFILES ALL_ROLES NONE
#### log_archive_dest on primary database
SQL> show parameter log_archive_dest
NAME TYPE VALUE
log_archive_dest string
log_archive_dest_1 string location=/u3/arch/orcl vali
d_for=(ALL_LOGFILES,ALL_ROLES)
db_unique_name=orclprmy
log_archive_dest_10 string
log_archive_dest_11 string
log_archive_dest_12 string
log_archive_dest_13 string
log_archive_dest_14 string
log_archive_dest_15 string
log_archive_dest_16 string
log_archive_dest_17 string
log_archive_dest_18 string
log_archive_dest_19 string
log_archive_dest_2 string service="orclstby1", LGWR ASYNC
NOAFFIRM delay=0 optional comp
ression=disable max_failure=0
max_connections=1 reopen=300 d
b_unique_name="orclstby1" net_ti
meout=30, valid_for=(all_logfi
les,primary_role)
log_archive_dest_20 string
log_archive_dest_21 string
log_archive_dest_22 string
#### log_archive_dest on standby database
SQL> show parameter log_archive_dest
NAME TYPE VALUE
log_archive_dest string
log_archive_dest_1 string location=/u3/arch/orclstby1 vali
d_for=(ALL_LOGFILES,ALL_ROLES)
db_unique_name=orclstby1
log_archive_dest_10 string
log_archive_dest_11 string
log_archive_dest_12 string
log_archive_dest_13 string
log_archive_dest_14 string
log_archive_dest_15 string
log_archive_dest_16 string
log_archive_dest_17 string
log_archive_dest_18 string
log_archive_dest_19 string
log_archive_dest_2 string service=orclprmy ASYNC valid_for
=(ONLINE_LOGFILE,PRIMARY_ROLE)
db_unique_name=orclprmy
log_archive_dest_20 string
log_archive_dest_21 string
log_archive_dest_22 string
log_archive_dest_23 string
log_archive_dest_24 string
log_archive_dest_25 string
#### spfile on standby database
</u2/oracle/product/11.2.0/dbhome_1/dbs> strings spfileorclstby1.ora
orcl.__db_cache_size=1040187392
orclstby1.__db_cache_size=1090519040
orcl.__java_pool_size=16777216
orclstby1.__java_pool_size=16777216
orcl.__large_pool_size=16777216
orclstby1.__large_pool_size=16777216
orcl.__oracle_base='/u2/oracle'#ORACLE_BASE set from environment
orclstby1.__oracle_base='/u2/oracle'#ORACLE_BASE set from environment
orcl.__pga_aggregate_target=536870912
orclstby1.__pga_aggregate_target=536870912
orcl.__sga_target=1610612736
orclstby1.__sga_target=161061273
orcl.__shared_io_pool_size=0
orclstby1.__shared_io_pool_size=0
orcl.__shared_pool_size=503316480
orclstby1.__shared_pool_size=469762048
orcl.__streams_pool_size=16777216
orclstby1.__streams_pool_size=0
*.archive_lag_target=0
*.audit_file_dest='/u2/oracle/admin/orclstby1/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/u2/oracle/oradata/orclstby1/control01.ctl','/u2/oracle/fast_recovery_area/orclstby1/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_file_nam
e_convert='orcl','orclstby1'
*.db_name='orcl'
*.db_recovery_file_dest='/u2/oracle/fast_recovery_area'
*.db_recovery_file_dest_size=5218762752
*.db_unique_name='orclstby1'
*.deferred_segment_creation=FALSE
*.dg_broker_start=TRUE
*.diagnostic_dest='/u2/oracle'
*.fal_client='orclstby1'
*.fal_server='orclprmy'
*.log_archive_config='dg_config=(orclprmy,orclstby1)'
*.log_archive_dest_1='location=/u3/arch/orclstby1 valid_for=(ALL_LOGFILES,ALL_ROLES) db_unique_name=orclstby1'
*.log_archive_dest_2='ser
vice=orclprmy ASYNC valid_for=(ONLINE_LOGFILE,PRIMARY_ROLE) db_unique_name=orclprmy'
*.log_archive_dest_state_2='ENABLE'
orcl.log_archive_format='orcl_%t_%s_%r.arc'
*.log_archive_format='orclstby1_%t_%s_%r.arc'
orclstby1.log_archive_format='orclstby1_%t_%s_%r.arc'
*.log_archive_max_processes=4
*.log_archive_min_succeed_dest=1
orcl.log_archive_trace=0
orclstby1.log_archive_trace=0
*.log_file_name_convert='orcl','orclstby1'
*.open_cursors=300
*.pga_aggregate_target=536870912
*.processes=
1500
*.remote_login_passwordfile='EXCLUSIVE'
*.sessions=1655
*.sga_target=1610612736
*.standby_file_management='AUTO'
*.undo_tablespace='UNDOTBS1'
</u2/oracle/product/11.2.0/dbhome_1/dbs>
Thank you for your help. -
Database Creation - Please Help!
Hi everyone, I am trying to do a database application for a uni project but have no idea where to start.
The data the database should be able to store is for a book shop and should be Title, Author, Price, Quantity, Description.
The user should be able to add records into the database, delete records, modify existing records and perform searches of existing records so that they may be able to locate a record by entering a key word or the title of the book or authors name.
I would also like to put a password onto the system but once again do not know how to acheive this.
I am not asking for a solution, only a helping hand in getting started, so if anyone can suggest the best way to start such a project I would be grateful.
Thanks everyoneThis Database is to be a stand alone application (runs on one pc only) so there would be only one terminal where the application is running.
The scale of the project is basic, I just have to create a database that can hold the information I have stated and also do the searches mentioned, if possible also have a password protection so that only certain users could access it.
Maybe you are looking for
-
New exchange emails not showing up in IOS6
Ok' I have been using IOS on iPad and Iphone against an Exchange2003 server for some time without problems. Upgraded to IOS6 on both devices a month or so ago and had endless issues with battery problems (on the phione) Found work arounds for those b
-
HT4946 How do I transfer apps and photos from my ipad to my iPhone?
I just bought a new iPhone5 after my other putting my other phone the the washing machine! How do I get my apps and pictures from my ipad to my iphone. I was not able to save anything from my other ohone.
-
How do I change the background behind the home page
My home page has a design behind it............. I would like to revert to its original plain design. The design it has now came through an email as a addition.
-
Hi All, Keynote is crashing more on me since moving to Leopard/Keynote 4.0.1, and I trying to figure out why. I create admittedly large presentation with 300-400 slides, most with quicktime movies in them. Still, this used to work fine on older lapto
-
Logic does not accept key command of Play from a section. Shift Enter makes display flashing. Another key command is normal.