error: conversion failed when converting from a character string to unique identifier when including a Smart Query selection in an Export Process

When using the Export process, users have the option of choose an Export Type, Selection, and Export Definition. However, when choosing an Export Type of Export Definition, and a Selection based on a Smart Query, they receive an error: conversion failed when converting from a character string to unique identifier
The error is caused by a Smart Query which has a primary key that is not a System Record ID or made up of a GUID.  To resolve:
  1. Administration > Application > Shell design > User-defined Smart Queries
  2. Edit the Smart Query used in the export
  3. Locate an acceptable Record ID (Revenue\System ID, Constituent record/etc.).  You may need to edit the smart query output fields to include one.
  4. Set the Record ID as the Primary key field on the "Set save options" tab
  5. Recreate the export with this newly adjusted Smart Query.

Environment

 3.0.516.41
 4.0.138, patch 2 ; 3.0.516, Service Pack 10

Was this article helpful?