assign_result - full360/sneaql GitHub Wiki

Command: ASSIGN_RESULT

description:

execute a SQL statement that returns a single value, store that value in a variable

parameters:

  • required - variable name to store first value returned

behavior:

  • first column of first row retrieved is assigned to variable... regardless of result set dimensions

examples:

/*-assign_result public_test_count-*/
select count(*) from public.test;

/*-assign_result a_string_value-*/
select 'some string';