0

Select syntax issue

Consider the following YQL statement:
CODE
select * from xml where url='http://www.google.com/reader/public/atom/user%2F05288119883720515136%2Flabel%2FYorkie'


What I really want to do is extract the gr:continuation value, but if I change the statement to:
CODE
select gr:continuation from xml where url='http://www.google.com/reader/public/atom/user%2F05288119883720515136%2Flabel%2FYorkie'

It gives a syntax error because of the colon. Note that other similar tags, such as "generator" work just fine.

Is there a way to escape a character in a situation like this, or is there another clever trick to employ in this situation?

by
1 Reply
  • QUOTE (earth2marsh @ Jul 24 2009, 07:16 PM) <{POST_SNAPBACK}>
    Consider the following YQL statement:
    CODE
    select * from xml where url='http://www.google.com/reader/public/atom/user%2F05288119883720515136%2Flabel%2FYorkie'


    What I really want to do is extract the gr:continuation value, but if I change the statement to:
    CODE
    select gr:continuation from xml where url='http://www.google.com/reader/public/atom/user%2F05288119883720515136%2Flabel%2FYorkie'

    It gives a syntax error because of the colon. Note that other similar tags, such as "generator" work just fine.

    Is there a way to escape a character in a situation like this, or is there another clever trick to employ in this situation?


    Drop the "gr:" and just project "continuation".

    CODE
    select continuation from xml where url='http://www.google.com/reader/public/atom/user%2F05288119883720515136%2Flabel%2FYorkie'


    -- Nagesh
    0

Recent Posts

in YQL