# \#arcscript

**URL:** https://community.cdata.com/tag/arcscript/112.md

[Latest](https://community.cdata.com/latest.md) · [Categories](https://community.cdata.com/categories.md) · [Tags](https://community.cdata.com/tags.md)

---

## [dbQuery with multiple statements](https://community.cdata.com/t/dbquery-with-multiple-statements/1247)

<div class="topic-metadata">

**Author:** [@Travis](https://community.cdata.com/u/Travis)\
**Replies:** 1\
**Last updated:** [December 24, 2025, 12:16pm UTC](https://community.cdata.com/t/dbquery-with-multiple-statements/1247 "2025-12-24T12:16:48Z")

</div>

How can I get this Sql Server dbQuery to work? The INSERT is completing fine, but I need to get the inserted identity PK and Arc is not picking it up. \<arc:set attr="db.query"\> insert into table (...) values (...); se…

---

## [Custom ArcScript Operations](https://community.cdata.com/t/custom-arcscript-operations/1196)

<div class="topic-metadata">

**Author:** [@Travis](https://community.cdata.com/u/Travis)\
**Replies:** 1\
**Last updated:** [September 25, 2025, 1:34pm UTC](https://community.cdata.com/t/custom-arcscript-operations/1196 "2025-09-25T13:34:44Z")

</div>

Is it possible to create my own Operations that I can call via arc:call? Or simple reusable methods/functions using arc:include perhaps that can return data? Or?

---

## [ArcScript to determine file type](https://community.cdata.com/t/arcscript-to-determine-file-type/1204)

<div class="topic-metadata">

**Author:** [@ericbux](https://community.cdata.com/u/ericbux)\
**Replies:** 7\
**Last updated:** [September 24, 2025, 9:27pm UTC](https://community.cdata.com/t/arcscript-to-determine-file-type/1204 "2025-09-24T21:27:03Z")

</div>

I have a trading partner who’s sending EDI with a file extension (.xml) and a Content-Type: text/plain and they’re also sending EPCIS xml files which are also of Content-Type: text/plain. I need to determine which files…

---

## [dbQuery check for null results](https://community.cdata.com/t/dbquery-check-for-null-results/1190)

<div class="topic-metadata">

**Author:** [@Travis](https://community.cdata.com/u/Travis)\
**Replies:** 1\
**Last updated:** [September 16, 2025, 9:28am UTC](https://community.cdata.com/t/dbquery-check-for-null-results/1190 "2025-09-16T09:28:59Z")

</div>

Is there a better way to check for null results from a dbQuery, I feel dirty for coming up with this: \<arc:set attr="db.query"\>select null as something;\</arc:set\>\<arc:call op="dbQuery" in="db" out="results"\> \<arc:if …

---

## [How to remove the last line in flat file using Arc script ??](https://community.cdata.com/t/how-to-remove-the-last-line-in-flat-file-using-arc-script/994)

<div class="topic-metadata">

**Author:** [@bala\_bk](https://community.cdata.com/u/bala_bk)\
**Replies:** 2\
**Last updated:** [January 16, 2025, 7:14am UTC](https://community.cdata.com/t/how-to-remove-the-last-line-in-flat-file-using-arc-script/994 "2025-01-16T07:14:15Z")

</div>

How to remove the last line in flat file using Arc script ?? The below script is to add the “END” on the last line but I need to remove the END which is present in the last line of a Flat-file?? \<arc:set attr=“file.fil…

---

## [Arc script](https://community.cdata.com/t/arc-script/993)

<div class="topic-metadata">

**Author:** [@bala\_bk](https://community.cdata.com/u/bala_bk)\
**Replies:** 2\
**Last updated:** [January 10, 2025, 2:18pm UTC](https://community.cdata.com/t/arc-script/993 "2025-01-10T14:18:57Z")

</div>

how to remove the first five lines in flat file using Arc script

---

## [Convert a JSON string into XML within a Script connector using ArcScript?](https://community.cdata.com/t/convert-a-json-string-into-xml-within-a-script-connector-using-arcscript/705)

<div class="topic-metadata">

**Author:** [@russell-jerseypost](https://community.cdata.com/u/russell-jerseypost)\
**Replies:** 1\
**Last updated:** [April 30, 2024, 9:06pm UTC](https://community.cdata.com/t/convert-a-json-string-into-xml-within-a-script-connector-using-arcscript/705 "2024-04-30T21:06:01Z")

</div>

How do I convert a JSON string to XML in ArcScript / Script connector?

---

## [Formatter \[…\] failed in the evaluation of … The error was: The attribute does not exist. This formatter cannot be called with nonexistent attributes.](https://community.cdata.com/t/formatter-failed-in-the-evaluation-of-the-error-was-the-attribute-does-not-exist-this-formatter-cannot-be-called-with-nonexistent-attributes/523)

<div class="topic-metadata">

**Author:** [@James\_B](https://community.cdata.com/u/James_B)\
**Replies:** 0\
**Last updated:** [November 14, 2023, 9:28pm UTC](https://community.cdata.com/t/formatter-failed-in-the-evaluation-of-the-error-was-the-attribute-does-not-exist-this-formatter-cannot-be-called-with-nonexistent-attributes/523 "2023-11-14T21:28:44Z")

</div>

This error is the equivalent of a null reference expression in ArcScript, and indicates that a formatter is applied to an attr that has not been defined in the script that you are working with. The attr that begins th…

---

## [Dynamic Bearer Token Authorization in the REST Connector](https://community.cdata.com/t/dynamic-bearer-token-authorization-in-the-rest-connector/137)

<div class="topic-metadata">

**Author:** [@Charlie\_S](https://community.cdata.com/u/Charlie_S)\
**Replies:** 1\
**Last updated:** [April 20, 2023, 8:49am UTC](https://community.cdata.com/t/dynamic-bearer-token-authorization-in-the-rest-connector/137 "2023-04-20T08:49:23Z")

</div>

Overview Bearer token authentication can be one of the more finicky authentication mechanisms to implement within Arc. The reason is because the token lifetime is very short and automatic token refresh isn’t something th…

---

## [Custom Code Snippets](https://community.cdata.com/t/custom-code-snippets/120)

<div class="topic-metadata">

**Author:** [@ericbux](https://community.cdata.com/u/ericbux)\
**Replies:** 1\
**Last updated:** [March 30, 2023, 2:07pm UTC](https://community.cdata.com/t/custom-code-snippets/120 "2023-03-30T14:07:47Z")

</div>

Hi, I was wondering if it was possible to write and save custom code snippets which would be available for use with any script block. I have a lot of custom scripts that I re-use often and was wondering it there was a …
