XML Oracle SQL character sets ORA-31011: XML parsing failed -


i have xml sql statement i'm using (see below oracle11g sql) overcome passing error (below), sql statement works strip out characters not specified in regexp_replace statement example following É Ë È need included in xml output file, include these , more there short cut include these characters in regexp_replace without naming long list of characters. have tried sql select dbms_xmlgen.convert(t.title) i've been told strips out invalid characters failed same parsing error below.

the reason why i'm using regexp_replace, failing because of characters (for example char(160) none-breaking space) in title database field.

is there simpler solution or have included long list of characters in regexp_replace.

thanks in advance.

declare  * error @ line: ora-31011: xml parsing failed ora-06512: @ line 8 

the trouble because i'm dealing different character

select xmlagg ( xmlelement ("referenceavgroup",                                                                                   xmlforest (cre_surr_id "societyseriesnumber",                               'series' "avgrouptype"),                           xmlelement ("prodtitle",                                                                                                     xmlforest (title "title",                                             tt_code_description "titletype")                                       )                                                                                                      )                )                                                                       (  select trim(regexp_replace(t.title, '[^a-za-z0-9 ,!@():.#’"*&+}/\©{ÂÀÃÏÎÔ܀ǿ%´_$()'',-`]', '', 1, 0, 'i')) title,                 'original'  tt_code_description,                 t.tt_code tt_codes,                 t.cre_surr_id            titles t           t.tt_code = com0300.title_type_registered)  cre_surr_id = prod.prod_series_cre_surr_id  

just update in end went below. there seem lot of control characters had been loaded files database, causing sql xml not parse. after using below , removing these characters sql xml ran fine. advice on subject.

regexp_replace(replace(prod.campaign_name,chr(160),''),'[[:cntrl:]]')


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -