Namrita Mohanty

Ranch Hand
+ Follow
since Sep 26, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Namrita Mohanty

Can someone please help on this!!!
11 years ago
Hi All,

Am using JavaFX to read a data a database ... I see the data when i print it on the console of the IDE but unable to get it displayed in the Table View. I have included all the code in the main class.
Please Help!!! (Let me know if anything else is needed to debug, am new to FX)

11 years ago
When I run the project I do not see any table view thing coming up.
11 years ago
If any one has a sample program to read a database please share as well. Would be of a great help n reference.
Thanks,
Namrita
11 years ago
HI, I new to JavaFX and was trying to read my database data into a Table view (GUI). Please help me!!!



*******************************
CONTROLLER CLASS:


*******************************

FXML:


*******************************

11 years ago
While it saves data into the Database the correct Thai format is getting saved....

For Eg:

Table: PostalCodes has three columns [Postalcode(numeric english),
District(Thai letters),
City(Thai letters)]

Only when we search for a Postalcode i.e a numeric value it displays the Thai letters of its correcponding District and City in "?". Like if its 3 letters in thai that should come it displays "???" for the District and for City of 7 letters in Thai its 7 Q marks that is getting displayed.

Any ideas?

Cheers!
Namrita
Oops!!! Just to make a small correction.... For other Tables also it isnt working... Thai data from database when tried to display it on the screen shows "?" Question marks....

Sorry... Please help?
Hello,

My Database has some data in Thai Language. While displaying it in the UI I see only "?" instead of the Thai letters.

This is happening for only one table in the database. Other tables are working fine. I mean it returns and displays the proper Thai name if stored.

Could anyone help?

Thanks,
Namrita
When I looked into the Database scripts that was run, there it was defined as:
"SMOKERSTATUSCODE" NOT NULL

I did change it to NULL and it is working now.... Earlier I had checked only with the Table details wherein it said in Column Properties that NULL is allowed but still it wasnt allowing inserting NULL as the scripts were run with "NOT NULL" [I suppose]
So many days I was not encountering this similar problem with the fix provided. But again I did run into this with another attribute:

"ORA-01400: cannot insert NULL into ("KUNALB"."NBCUSTOMER"."SMOKERSTATUSCODE")"

In the mapping file I have set its "not-null" value as "false" still am facing this.

Suggestions please...
"2010-10-14 10:55:14,750 WARN [http-8080-1] org.hibernate.util.JDBCExceptionReporter:357 - SQL Error: 1, SQLState: 23000
2010-10-14 10:55:14,750 ERROR [http-8080-1] org.hibernate.util.JDBCExceptionReporter:454 - ORA-00001: unique constraint (KUNALB.SYS_C0071113) violated

2010-10-14 10:55:14,750 WARN [http-8080-1] org.hibernate.util.JDBCExceptionReporter:357 - SQL Error: 1, SQLState: 23000
2010-10-14 10:55:14,750 ERROR [http-8080-1] org.hibernate.util.JDBCExceptionReporter:454 - ORA-00001: unique constraint (KUNALB.SYS_C0071113) violated

2010-10-14 10:55:14,750 ERROR [http-8080-1] org.hibernate.event.def.AbstractFlushingEventListener:532 - Could not synchronize database state with session
org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:94)"


The above error is thrown though I do not have the record that am trying to save in the Database.

Any suggestions?
Thanks. It did solve my problem.

Regards,
Namrita
I found out the mapping file :

<property name="otheridnumber" type="java.lang.String">
<column name="OTHERIDNUMBER" length="50" />
</property>

it doesn't say if it can be "null" or not like it says for some of the fields [though not all]

<many-to-one name="nbgender" class="com.hib.reverse.Nbgender" fetch="select">
<column name="GENDERCODE" precision="22" scale="0" not-null="true" />
</many-to-one>

Thanks,
Namrita
Even if i make the otherIDNumber work by hardcoding the value I get the below error:

org.springframework.dao.InvalidDataAccessApiUsageException: object references an unsaved transient instance - save the transient instance before flushing: com.ing.workstation.resource.appcapture.dto.NationalityCodes; nested exception is org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: com.ing.workstation.resource.appcapture.dto.NationalityCodes

Could you please suggest. Anyone??

Thanks,
Namrita
Hello SanathanaKrishanan,

Could you please specify about which mapping file should I be checking out for the database column properties. I am not aware of it.

Thanks,
Namrita