Hi Ben,

Thanks for replying. Yes, I've tried assigning the noSQLEncoding variable
before and after the DirectDBMS call as you've suggested, but to no avail.
In addition to setting noSQLEncoding to true before and then false after,
I've set it to false before (which appears to be what the the doco
requires for single quote characters to be automatically be doubled), but
that didn't work either.

noSQLEncoding
This configuration variable determines whether text in Direct DBMS actions
is SQL-encoded by default (single quote characters doubled). The default
value is false.

- Matt


[email protected] writes:
>Have you tried this, I do this all the time on special needs
>
>Just before the insert issue this 
><@ASSIGN noSQLEncoding true>
>
>And just after the statement issue this
><@ASSIGN noSQLEncoding false>
>
>Ben
>
>-----Original Message-----
>From: Matt Muro [mailto:[EMAIL PROTECTED] 
>Sent: Thursday, April 20, 2006 9:23 AM
>To: [email protected]
>Subject: Witango-Talk: noSQLEncoding ini setting
>
>I searched through the forum archives and saw some posts regarding Witango
>5.5 and SQL encoding in DirectDBMS actions. It sounds like people WERE
>able to get the noSQLEncoding=false setting in the 5.5 witango.ini to
>automatically quote meta tag values. This doesn't seem to be working for
>me, requiring me to add "encoding=sql" to all meta tag variables in my SQL
>insert/update statements. Is this .ini setting fried in 5.5 (Win32) or am
>I doing something wrong? Thank you.
>
>We're using: Witango Application Server 5.5.009 Liquorice (Win32)
>[Professional Edition]
>
>This worked in 5.0:
>
>[in witango.ini]   NOSQLENCODING=false
>
>INSERT INTO users ( user_id, user_name, date)
>VALUES (<@VAR name="user_id" scope="local">, '<@VAR name="user_name"
>scope="local">', sysdate)
>
>-- producing the extra single quote in the user's name, O'Malley (damn
>Irish :)
>INSERT INTO users ( user_id, user_name, date)
>VALUES ( 1, 'O''Malley', sysdate)
>
>In 5.5, I have to add encoding=sql to my meta tags even though I have
>NOSQLENCODING=false set in the witango.ini
>
>[in witango.ini]   NOSQLENCODING=false
>
>INSERT INTO users ( user_id, user_name, date)
>VALUES (<@VAR name="user_id" scope="local">, '<@VAR name="user_name"
>scope="local" encoding="sql">', sysdate)
>
>INSERT INTO users ( user_id, user_name, date)
>VALUES ( 1, 'O''Malley', sysdate)
>
>
>
>From the "Witango 5.5 Programmer's Guide" page 494 (510 in PDF).
>
>noSQLEncoding
>Valid in all scopes This configuration variable determines whether text in
>Direct DBMS actions is SQL-encoded by default (single quote characters
>doubled). The default value is false. Setting the value to true turns off
>automatic SQL-encoding in Direct DBMS actions. If noSQLEncoding is set to
>true, you can use the ENCODING=SQL attribute on most value-returning meta
>tags to SQL-encode the value returned by that meta tag. 
>
>
>From the "Witango 5.5 Programmer's Guide" page 73 (89 in PDF).
>----------------------------------------------------------------------------
>------------------------
>The SQL encoding type converts the specified value by doubling all
>occurrences of the single quote character. Witango Server automatically
>performs SQL encoding on meta tag values substituted in Direct DBMS SQL,
>except when the configuration variable noSQLEncoding is set to true. The
>SQL ENCODING attribute value is generally appropriate only when
>noSQLEncoding is set to true, and allows you to toggle SQL encoding on or
>off for particular meta tags. 
>
>
>________________________________________________________
>Matt Muro                                      [EMAIL PROTECTED]
>Harvard University                           phone:  617.998.8522
>Division of Continuing Education       fax:      617.495.9176
>
>________________________________________________________________________
>TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
>
>
>________________________________________________________________________
>TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf




________________________________________________________
Matt Muro                                      [EMAIL PROTECTED]
Harvard University                           phone:  617.998.8522
Division of Continuing Education       fax:      617.495.9176

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to