comboboxes doesnt work on server

when the app is running in my own macbook everything seems to be good. On the server of the internet service provider,, the page appears as it should be. In the textfield is number of rows in the database and it is ok.


is that comboboxes should be populated also, but they are not.

The app opens connection to db when it counts the number of rows in the db. Connection stays open until you click on ‘Paina Kaasua!’.
All the text in the table comes from java code, not from db.
Max number of printed rows is limited to 800.
Eclipse 3.5.1 makes autoparaati.war. Mysql connector is 5.1.12. My tomcat 6.0.26

It is here:


Well the application immediately throws a java.lang.NullPointerException at so that could be something that you atleast need to fix :slight_smile:

Artur, thanks for your answer. This exception is an interesting point. App was ok when I posted the message to the list. But now I gave the exception like yours.
I uploaded the app again and it appears on the browser as it should be but still doesnt populate combos. I do not have any idea what is going on the server.


I wrote code a little more. Each connection to mysql is now closed immediately.
Is there some difference between tomcat 5.5.26 and 6.0.26 from the angle of Vaadin?

Vaadin is completely a GUI framework, so it should not have any effect on your database connection. You could do some logging of the result sizes on the collections that the database returns, before you put the result into the selects.

If the system.outs return 0 then you can safely assume that Vaadin is not the problem. If the sizes are correct then it is probably something with how you put the data into the selects.

Hei Jens,

Problem is that everything seems to be good on my MacBook with Eclipse / Mysql / Tomcat. But on the web site of
ComboBoxes are not populated.
ComboBoxes are calling here: try { horizontalSplit.setFirstComponent(comboView.setDataSource()); } catch (JSONException e) { // TODO Auto-generated catch block e.printStackTrace(); }
ComboBoxes are populating here:
rivitLkm.setDescription(“Tulostettavien rivien määrä”);

	JSONArray jArray = new JSONArray();
	JSONObject jObject = new JSONObject();
	String arvoS = "";
	jArray = hakuLauseVaadin.kaikkiAlkuarvotComboboxVaadin();

	for (int i = 0; i < combos.length; i++) {

= new ComboBox(comboId[i]

	for (int i = 0; i < jArray.length(); i++) {
		jObject = jArray.getJSONObject(i);
		for (int ic = 0; ic < comboId.length; ic++) {
			if (!jObject.isNull(comboId[ic]

)) {
arvoS = jObject.get(comboId[ic]

	for (int i = 0; i < combos.length; i++) {


	// combos[0]


	return formLayout;


Did you log what mysql returned to your JArray and JObject as I suggested?

Does it mean that there is a limit of how many items a ComboBox can have? Or what?

No, it means that you should verify that you actually get data from the database. In other words, make sure the database query does not return null or an empty set.

The resultset from database was ok. But your answer was so demanding that I installed Eclipse and Vaadin again - and - it is working now!

I have had good luck with the list of Vaadin. This is the first list in the java/internet that I have got answers to my questions. Very good culture!!
Next time when we have a Vaadin celebrition like 4 - 5 months ago in Pitäjänmäki - I will ‘buy’ Spring Water to all those wise experts who has answered my questions :smiley: