sonia pandit

Ranch Hand
+ Follow
since Apr 19, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by sonia pandit

How do you skin the af|statusIndicator. I want to set the background color to white so that only the "O' is showing and I would like to stretch the "O".
12 years ago
JSF
@OneToOne(optional = false,cascade = CascadeType.ALL, fetch = FetchType.EAGER)
@JoinColumn(name = "PHONE_ID", unique = true, nullable = false, updatable = false)
private Phones telephoneNumber;


is what I have now, I am getting the following error:


eption [EclipseLink-4002] (Eclipse Persistence Services - 2.1.3.v20110304-r9073): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00904: "TELEPHONENUMBER_PHONES_ID": invalid identifier

Error Code: 904
Call: INSERT INTO PHONES (TELEPHONENUMBER_PHONES_ID, PHONE_NUMBER) VALUES (?, ?)
bind => [101, 5716120000]
Query: InsertObjectQuery(testonetoone.Phones@1ea0105)
at org.eclipse.persistence.exceptions.DatabaseException.sqlException(DatabaseException.java:324)


I really appreciate. need to get it resolved ASAP
IT is a bidirectional oneToOne. That is not where my error is though.

Caused by: java.sql.SQLSyntaxErrorException: ORA-00904: "TELEPHONENUMBER_PHONES_ID": invalid identifier

at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:440)


I changed the TelephoneNumberMandatory to TELEPHONENUMBER
No. I am still getting an error

... 2 more
Caused by: java.sql.SQLSyntaxErrorException: ORA-00904: "TELEPHONENUMBERMANDATORY_PHONES_ID": invalid identifier

caused by: java.sql.SQLSyntaxErrorException: ORA-00904: "TELEPHONENUMBERMANDATORY_PHONES_ID": invalid identifier

Phones.java




Customer.java

TestOneToOne.java


persistence.xml




[/code]
Now I have a problem with a one to many bidirectional mapping. I get a java.sql.SQLIntegrigyConstraintViolationException Cannot insert NULL into

example of what I have

@JoinColumn(name = "AuthorNo", referencedColumnName = "AuthorNo")
@ManyToOne
private Authors authorNo;


@OneToMany(mappedBy = "authorNo", cascade=CascadeType.ALL)
private List<Books> booksCollection= new ArrayList<Books>();

I would really appreciate help in fixing this problem
This is the error message I get when I try to run my sample app.

For a one to many bidirectional mapping with many to one on the child. I have both the classes in the same package and listed in persistence.xml.
I am stuck. Any help would be appreciated.

Thanks,
I am trying to follow an example in a book. The example says to copy over struts.jar to the web-inf/lib directory
of tomcat where the example is installed. There is no struts.jar included with the download of struts.
Not sure which file they are referring to.

Thanks,

Sonia
14 years ago