Single quotes Escape from parameter values

Defined one parameter called "display_name" in sql editor and passing dynamic values in to it and capture in the where ( org_name in ('x','y','I'am there') ) clause as per below .however few values are already have single quotes in it (ex : I'am there) and throwing an error . any help? how to escape single quotes ?

select distinct ltrim(rtrim(a.email)) as email from table_name a
-where
and ltrim(rtrim(b.display_name)) in ({{display_name}})

 

{% form %}

    
email:
    type: multiselect
    default: all
    options:
        labels: email
        values: email

{% endform %}

Reply Oldest first
  • Oldest first
  • Newest first
  • Active threads
  • Popular
Like Follow
  • 1 mth agoLast active
  • 38Views
  • 1 Following

Create A New Discussion

Share your thoughts