export to email

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-14-2023 12:48 PM - edited 04-14-2023 12:50 PM
I have a requirement to disable this popup. Even if the export data exceeds a defined limit the system should not allow email export. Rather it should restrict the user from exporting it with a message that export limit has been exceeded
Please help me with this
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-18-2023 08:17 AM - edited 04-18-2023 02:27 PM
Hi,
The suggestion of a BR won't work, actually defining a BR as suggested proved that. The Export Limit feature is defined here:
And for some tables, there are UI actions:
https://[instance_name].service-now.com/sys_ui_action_list.do?sysparm_query=GOTOnameLIKEexport&sysparm_view=
I have no idea how you would enforce export limits in general without changing the related system property for the export type. Define those in the documentation if they don't exist in the sys_properties table to override the default value in the documentation.
Mayby other Community members can comment on disabling the email choice when exporting data. You may propose that capability, see:

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2023 04:54 AM
Thanks for your response @Bert_c1 and @Rahul Kumar17
Is there any way we can restrict this input email to only a particular domain like "@abcd.com" instead of all types of domain
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2023 07:55 AM
Hi Amrit4,
I believe that feature is designed to prevent a session timeout when exporting a "large" amount of data. The user session is subject to the Transaction Quota Rule named 'UI Transactions', which is 298 seconds OOB. The export transaction can fail if that time limit is exceeded. To avoid that, the export can be done in the background and a email notification sent once it is done. And I expect the attachment can exceed some email-related limit and for that, the email delivery would fail.
I do not work email configuration in the instance. There may be some 'System Notification' or 'System Policy' related to email that can do what you want, but you'll need to read the related documentation or maybe some Community member has a suggestion.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2023 09:50 PM
Hi Amrit,
Yes, it is possible to restrict input email to a particular domain like "@abcd.com" in ServiceNow. One way to do this is by using a client script in the form of a script include.
Here's an example script that you can use to achieve this:
// Define the allowed email domain
var allowedDomain = "@abcd.com";
// Get the email field element
var emailField = g_form.getControl('email_field_name');
// Get the value of the email field
var emailValue = emailField.value;
// Check if the email is valid and belongs to the allowed domain
if (emailValue && emailValue.indexOf('@') > -1 && emailValue.split('@')[1] !== allowedDomain) {
alert('Email must belong to ' + allowedDomain);
emailField.value = '';
}
You can replace 'email_field_name' with the actual name of the email field in your form. This script will check if the email entered in the field belongs to the allowed domain. If it doesn't, it will show an alert message and clear the email field.
Thanks,
Rahul Kumar
Thanks,
Rahul Kumar

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-26-2023 03:26 AM - edited 04-26-2023 03:26 AM
Thanks a ton for your answer @Rahul Kumar17
However i want this to happen while we try to export a large data table and it asks for an email there. Below screenshot is for your reference:
Will it work here?