Hello to everyone.
Can you tell me how can I escape the char '%' to an sql query?
I need to execute an sql query like 

authorize_check_query = "(SELECT rc.ID,es.USERNAME||'@freeRADIUS'
USERNAME, rc.ATTRIBUTE ATTRIBUTE, rc.OP OP, rc.VALUE VALUE FROM
EPIN_SERIALS es, TMP_RADCHECK rc WHERE ATTRIBUTE NOT LIKE '%Password%'
                                                ^^^^^^^^^^^^^^^^^^^^^^^
and es.username = '${sql_user_name2}') UNION (SELECT
rc.ID,es.USERNAME||'@freeRADIUS' USERNAME, rc.ATTRIBUTE ATTRIBUTE,
rc.OP OP, es.PASSWORD VALUE FROM EPIN_SERIALS es, TMP_RADCHECK rc
WHERE ATTRIBUTE LIKE '%Password%' and es.username =
'${sql_user_name2}')" 

but the substitution is not happening right.
Sorry if it seems trivial but I am in a panic situation...



--   
  Kostas Zorbadelos
  Currently at: Otenet IT Department 
  mailto: [EMAIL PROTECTED]
  
  Out there in the darkness, out there in the night
  out there in the starlight, one soul burns brighter
  than a thousand suns.


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to