You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by ooper <ma...@roomity.com> on 2005/12/09 20:34:58 UTC
Question on CDATA usage
Just wondering if it matters how much of the query you include within the CDATA element? Is one of these preferable over the other? Why? <= GETDATE() ]]> SELECT * FROM my_table WHERE my_column = #value# AND <= GETDATE() ]]> TIA, Brian Barnett
Broadband interface (RIA) + mail box saftey = http://iBatis_for_Java_Users_List.roomity.com
*Your* clubs, no sign up to read, ad supported; try broadband internet.
Re: Question on CDATA usage
Posted by Nathan Maves <Na...@Sun.COM>.
I assume that you meant something like
<![CDATA[
SELECT *
FROM my_table
WHERE my_column = #value# AND
my_date <= GETDATE()
]]>
and
SELECT *
FROM my_table
WHERE my_column = #value# AND
my_date <![CDATA[<=]]> GETDATE()
I would choose the first example for readability. I don't think that
there are any performance implications.
Nathan
On Dec 9, 2005, at 12:34 PM, ooper wrote:
> Just wondering if it matters how much of the query you include
> within the CDATA element?
>
> Is one of these preferable over the other? Why?
>
>
> SELECT *
> FROM my_table
> WHERE my_column = #value# AND
> my_date <= GETDATE()
> ]]>
>
>
> SELECT *
> FROM my_table
> WHERE my_column = #value# AND
>
> my_date <= GETDATE()
> ]]>
>
> TIA,
> Brian Barnett
>
>
> Broadband interface (RIA) + mail box saftey = http://
> iBatis_for_Java_Users_List.roomity.com
> *Your* clubs, no sign up to read, ad supported; try broadband
> internet.
Re: Question on CDATA usage
Posted by Larry Meadors <lm...@apache.org>.
What is the difference?
LArry
On 12/9/05, ooper <ma...@roomity.com> wrote:
> Just wondering if it matters how much of the query you include within the
> CDATA element?
>
> Is one of these preferable over the other? Why?
>
> SELECT *
> FROM my_table
> WHERE my_column = #value# AND
> my_date <= GETDATE()
> ]]>
>
>
> SELECT *
> FROM my_table
> WHERE my_column = #value# AND
> my_date <= GETDATE()
> ]]>
>
> TIA,
> Brian Barnett
>
>
> Broadband interface (RIA) + mail box saftey =
> http://iBatis_for_Java_Users_List.roomity.com
> *Your* clubs, no sign up to read, ad supported; try broadband internet.
>