Change column Headers in export Excel/CSV?

Liyakhat2
Tera Expert

Hi Team,

 

We are exploring a way to change column header names while downloading a report/exporting

data through excel/CSV we are having two cases

 

1.can we change column headers to different names while downloading? Is this possible through a view?

2.Can we change data from the table to uppercase and download it in excel?

use case: we have a system developed in SAP they were using different columns and data formats earlier where they got data from SharePoint and share point is being replaced by ServiceNow.

1 ACCEPTED SOLUTION

palanikumar
Giga Sage

Hi,

There is one option available via data base view. Follow the steps:

1) Create a database view

2) You can add only one table to database view. Add your table with some variable prefix. Remember this prefix. Refer screenshot1 below

 

find_real_file.png

3) Goto System Definition > Language File and create a new language file with following details

- Table = your database view created

- Label = The name you want in the export

- Plural = Plural form of label

- Element = The field in database that need to be renamed. You have to prefix the variable prefix used in database view (from step 2). I gave inc as variable prefix in database view. So, I used inc_short_description to refer short_description field. Refer screenshot2

find_real_file.png

And the output is below. You can use the Database View for export

find_real_file.png

 

Thank you,
Palani

View solution in original post

10 REPLIES 10

palanikumar
Giga Sage

Hi,

There is one option available via data base view. Follow the steps:

1) Create a database view

2) You can add only one table to database view. Add your table with some variable prefix. Remember this prefix. Refer screenshot1 below

 

find_real_file.png

3) Goto System Definition > Language File and create a new language file with following details

- Table = your database view created

- Label = The name you want in the export

- Plural = Plural form of label

- Element = The field in database that need to be renamed. You have to prefix the variable prefix used in database view (from step 2). I gave inc as variable prefix in database view. So, I used inc_short_description to refer short_description field. Refer screenshot2

find_real_file.png

And the output is below. You can use the Database View for export

find_real_file.png

 

Thank you,
Palani

Thanks Palani

2.Can we change data from the table to uppercase and download it in excel?

we have ids created in a column and the data is in lowercase/upper case can we change it to uppercase in the downloaded file?

Do you have any idea on this?

Hi,

Data can't be changed.

Thank you,

Palani

Thank you,
Palani

@Ankur Bawiskar @palanikumar Hi both, 

Works great with fields on that table but can this be done with dot-walked fields? For example my database view is on cmdb_ci_computer, but I need location.name and parent.name (these are both called 'Name' on the export which I need to change)

Thanks!

Hi,

You can't change language field on a dot walked field.

You can join the table of dot walked field and then update the language entries.

Thank you,

Thank you,

Palani

Thank you,
Palani