Jump to content
We've recently updated our Privacy Statement, available here ×

Excel Datasource -> each field has String as type


adiboing

Recommended Posts

Hello dudes,

this is another thread from me, maybe I solve it like the others by myself but actually this time I'm almost about to quite....

I searched the web for a propper instruction about a, how to use ireports with a excel datasource, futile...

My problem is that each field has the datatype String. Alright lets change the datatype in the fieldproperty to, lets say integer, futile...

I don't know why its not working like it should, but I created a video to show you my problem precisely. All you got to do is unzip my attached file and start the .html file. A video will start and show my display with ireports.

For explantation while the vid is running.

1. In the beginning you'll see how I get the fields all as String. Important are the fields "ID" and "Gesamt Brutto". (Some names are written in german but don't bother).

2.Then I change the field "ID" to type Integer. This is working well. In Excel the column "ID" has "Standart" formatting with just numbers 1,2,3....per cell.

3. Now I change the field "Gesamt Brutto" to a float type. In Excel this column has the formatting "Numeric". When I preview my report a error occures. When I change the type to integer, same scenario. When I use it as normal String type, everything is working.

4. Additional Question:

When I preview my report after the typecast back to string I mark 3 rows with the mouse. These rows have all the same name "Hirschmann". How can I create a var or something to check if the last value of a field is the same as the present. Because I would like to sum the "Gesamt Brutto" when the name is the same. So when theres three times "Hirschmann" do '6.484 + 24.023 + 84.390'. Anybody got an idea?

5. End

 

Hope anybody can help me now... not like the other times =/

peace Adi

 

 

 

 

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...