Change name of the textbox in SSRS report
I would like my report to display a column name different from what it is in the source. For example, if the data source has column name as NumberKey and I want my report to display as Number, how do I do it? My data source is a cube and hence queried by MDX. If it was a relational database it would be easier as I could always apply name change in the SQL statement. Many thanks.Mpumelelo
June 28th, 2012 12:13pm

Hey Mpumelelo, It is not always required to rename your fields within your query itself. SSRS provides mechanisms to rename fields at the report level as well. Once you setup your query within the Dataset, navigate to the section known as "Fields". Here you see a mapping between the Field Name and the Field Source. Field Name is the Report Level name for your field (user configurable) and Field Source defines from where in your datasource, you got this field from (in case of cube data source, you will see the Field source have some XML stuff in it). Now, in your case, you should be seeing NumberKey in both the Field Name and the Field Source. Just change the Field Name to Number and hit OK. You will thereafter be able to use this field as Number itself (e.g. Fields!Number.Value). What you are doing is renaming the NumberKey field in your data source to Number at the Report level. Just remember that if you want your field name to have a space in it, use an underscore character to indicate the space. In the below screenshot, I have renamed the "SomeField" from the database to "Renamed Field" in the report ( _ indicates space ). HTH. Cheers, IceQBPlease mark correct answers :)
Free Windows Admin Tool Kit Click here and download it now
June 28th, 2012 12:25pm

Many thanks IceQB. Im relatively new to SSRS. Im familiar with the place where you have referred me to so that I can rename my filed but Ive never taken thought that I can use it for that purpose. Your help is much appreciated.Mpumelelo
June 28th, 2012 3:00pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics