Problem getting RSS feeds on Scandinavian characters

Hello

I have problem in retrieving the RSS feeds of some streams, Scandinavian characters are converted.
When I discover stream source, characters are correct. So I guess that the problem could be my XML request.
Example of RSS feed
http://www.mtv3.fi/rss/urheilu_f1.rss
I get results like
Pakokaasuvirtausten hyödyntäminen rajoitetaan minimiin
That should say
Pakokaasuvirtausten hyädyntäminen rajoitetaan minimiin
And the problem occur not e.g. foods from here
http://www.hs.fi/uutiset/rss/
I use below table and package to get RSS fead and store it in the clob column
CREATE TABLE rss
  (payload CLOB
  );

create or replace
PACKAGE RSS_UTIL AS
  g_wallet_path     CONSTANT VARCHAR2(200) := 'file:/somepath/wallets';
  g_wallet_pass     CONSTANT VARCHAR2(200) := 'verysecret';
  g_collection_name CONSTANT VARCHAR2(200) := 'RSS_RESPONSE';
  g_user_agent      CONSTANT VARCHAR2(200) := 'Mozilla/5.0';
--------------------------------------------------------------------------------
  PROCEDURE get_rss_feed(
    p_url IN VARCHAR2
  );
END;
/
create or replace
PACKAGE BODY RSS_UTIL AS
  PROCEDURE get_rss_feed(
    p_url IN VARCHAR2
  )
  AS
    l_clob      CLOB;
    l_buffer    VARCHAR2(32767);
    l_http_req  utl_http.req;
    l_http_resp utl_http.resp;
  BEGIN
  --  
    --utl_http.set_wallet(g_wallet_path, g_wallet_pass);
    --
    utl_http.set_proxy(apex_application.g_proxy_server, NULL);
    --
    l_http_req  := utl_http.begin_request(p_url);
    --
    utl_http.set_header(l_http_req, 'User-Agent', g_user_agent);
    --
    l_http_resp := utl_http.get_response(l_http_req);
    --
    dbms_lob.createtemporary(l_clob, FALSE);
    dbms_lob.open(l_clob, dbms_lob.lob_readwrite);
    --
    BEGIN
      LOOP
        utl_http.read_text(l_http_resp, l_buffer);
        dbms_lob.writeappend(l_clob, LENGTH(l_buffer), l_buffer);
      END LOOP;
    EXCEPTION WHEN utl_http.end_of_body THEN
      NULL;
    END;
    --
    utl_http.end_response(l_http_resp);
    --
    EXECUTE IMMEDIATE 'TRUNCATE TABLE RSS';
    INSERT INTO RSS VALUES(l_clob);
    COMMIT;
  --
  END;
END;
/

BEGIN
  rss_util.get_rss_feed('http://www.mtv3.fi/rss/urheilu_f1.rss');
END;
/
And I query the clob data by
SELECT extractValue(value(t), '//link/text()')   AS LINK,
  extractValue(value(t), '//category[1]/text()') AS category,
  extractValue(value(t), '//category[2]/text()') AS sub_category,
  extractValue(value(t), '//title/text()')       AS title,
  extractValue(value(t), '//description/text()') AS description,
  extractValue(value(t), '//author/text()')      AS author,
  extractValue(value(t), '//pubDate/text()')     AS rss_date
FROM rss,
  TABLE(xmlsequence(extract(xmltype(rss.payload),'//rss/channel/item'))) t ;
I also like Apex app if you like check
http://ActioNet.homelinux.NET/HTMLDB/lspdemo?p=48
Just press the Connect button to enter application.

Only difference is I have store RSS apex_collection clob column and where questioning the report.

How can I change my code or the query to solve this problem?

Kind regards
Jari

http://dbswh.webhop.NET/dbswh/f?p=blog:Home:0

OK, finally found the explanation...

We will check the HTTP response for each request headers:

http://www.HS.fi/Uutiset/RSS/

SQL> set serveroutput on
SQL> DECLARE
  2
  3    req     utl_http.req;
  4    resp    utl_http.resp;
  5    hname   varchar2(200);
  6    hvalue  varchar2(200);
  7
  8  BEGIN
  9
 10    req  := utl_http.begin_request('http://www.hs.fi/uutiset/rss/');
 11    utl_http.set_header(req, 'User-Agent', 'Mozilla/5.0');
 12    resp := utl_http.get_response(req);
 13
 14    for i in 1..utl_http.get_header_count(resp) loop
 15      utl_http.get_header(r => resp ,n => i, name => hname, value => hvalue);
 16      dbms_output.put_line(hname || ' : ' || hvalue);
 17    end loop;
 18
 19    utl_http.end_response(resp);
 20
 21  END;
 22  /

Date : Thu, 08 Dec 2011 22:01:21 GMT
Cache-Control : max-age=120
Expires : Thu, 08 Dec 2011 22:03:21 GMT
Content-Type : text/xml;charset=utf-8
Content-Length : 8208
Keep-Alive : timeout=15, max=99
Connection : Keep-Alive
 

Charset is UTF-8 and consistent with the XML prologue.

Now, the flow of problem:

http://www.MTV3.fi/RSS/urheilu_f1.RSS

SQL> DECLARE
  2
  3    req     utl_http.req;
  4    resp    utl_http.resp;
  5    hname   varchar2(200);
  6    hvalue  varchar2(200);
  7
  8  BEGIN
  9
 10    req  := utl_http.begin_request('http://www.mtv3.fi/rss/urheilu_f1.rss');
 11    utl_http.set_header(req, 'User-Agent', 'Mozilla/5.0');
 12    resp := utl_http.get_response(req);
 13
 14    for i in 1..utl_http.get_header_count(resp) loop
 15      utl_http.get_header(r => resp ,n => i, name => hname, value => hvalue);
 16      dbms_output.put_line(hname || ' : ' || hvalue);
 17    end loop;
 18
 19    utl_http.end_response(resp);
 20
 21  END;
 22  /

Server : nginx
Date : Thu, 08 Dec 2011 22:04:20 GMT
Content-Type : text/xml
Connection : close
Vary : Accept-Encoding
Last-Modified : Thu, 08 Dec 2011 21:56:56 GMT
ETag : "be970e-fb94-4b39bbf33fa00"
Content-Length : 64404
Cache-control : public
Accept-Ranges : bytes
 

The Content-Type header does not specify the character set, so according to the HTTP/1.1 protocol, the default character set is ISO-8859-1, which is not compatible with the declared XML coding.

As a quick fix, you can use this to retrieve the binary content instead:

SQL> SELECT extractValue(value(t), '/item/link')        AS LINK,
  2         extractValue(value(t), '/item/category[1]') AS category,
  3         extractValue(value(t), '/item/category[2]') AS sub_category,
  4         extractValue(value(t), '/item/title')       AS title,
  5         extractValue(value(t), '/item/description') AS description,
  6         extractValue(value(t), '/item/author')      AS author,
  7         extractValue(value(t), '/item/pubDate')     AS rss_date
  8  FROM TABLE(
  9         XMLSequence(
 10           extract(
 11             xmltype(httpuritype('http://www.mtv3.fi/rss/urheilu_f1.rss').getBLOB(), nls_charset_id('AL32UTF8'))
 12           , '/rss/channel/item'
 13           )
 14         )
 15       ) t
 16  WHERE rownum < 5
 17  ;

LINK                                                                             CATEGORY           SUB_CATEGORY      TITLE                                                           DESCRIPTION                                                                      AUTHOR        RSS_DATE
-------------------------------------------------------------------------------- ------------------ ----------------- --------------------------------------------------------------- -------------------------------------------------------------------------------- ------------- -------------------------------
http://www.mtv3.fi/urheilu/f1/uutiset.shtml/2011/12/1457011/kovalaisen-talli-vah F1                                   Kovalaisen talli vahvisti uuden aero-pomon palkkaamisen         F1-sarjan Caterham-talli vahvisti torstaina pestanneensa John Ileyn tallin uudek               08 Dec 2011 23:27:07 +0200
http://www.mtv3.fi/urheilu/f1/uutiset.shtml/2011/12/1456562/grosjeanista-raikkos F1                                   Grosjeanista Räikkösen tallitoveri?                             Lotus F1 Team on pestannut ensi kaudeksi Romain Grosjeanin Kimi Räikkösen tallit               08 Dec 2011 12:07:21 +0200
http://www.mtv3.fi/urheilu/f1/uutiset.shtml/2011/12/1456557/myos-sauber-eroaa-f1 F1                                   Myös Sauber eroaa F1-talliyhdistyksestä                         Myös Sauber-talli on päättänyt erota Ferrarin ja Red Bullin tapaan F1-talliyhdis               08 Dec 2011 12:03:49 +0200
http://www.mtv3.fi/urheilu/f1/uutiset.shtml/2011/12/1456003/usan-gp-pysyi-f1-kal F1                                   USA:n GP pysyi F1-kalenterissa                                  Kansainvälisen autoliiton FIA:n maailmanneuvoston keskiviikkona julkaisemaan kau               07 Dec 2011 20:01:52 +0200
 

or do it via UTL_HTTP. READ_TEXT with a RAW buffer.

Edited by: odie_63 Dec 9. 2011 00:00

Tags: Database

Similar Questions

  • How to get RSS feeds on the Journe Air 801 via the external memory card?

    I bought the Journe Air 801 digital photo frame and the manual says 'save the RSS feed of the album that you want to display in the .rss format and add to the external memory card', but he said not how you create this .rss file or copy it to your memory card. Anyone know how I can get a picasa rss in this format?

    I've successfully added a picasa feed manually in the framework but as picasa updates only the RSS if new galleries are added, not new photos, the photo feed is not updated on the frame so I would change the rss address.
    Thank you

    Hello palomaroma,

    I am also a user of Journe Air 801.
    To add RSS feeds, please install the software from the disc attached.
    Insert the sd card into the frame. Connect the frame to your computer.
    Start the Photo Frame Wizzard. Flow RSS Acount (s) is displayed.
    Now you can add RSS feed addresses.

    Best regards

  • Submit an RSS feed to itunes, but I keep getting a message saying 'cannot submit your feed. There is no description tag in your diet, or the description tag is empty. "Any advice on how to solve this problem?

    Our podcast is released through Libsyn, who confirmed to me that our RSS feed is valid. I talked to two Libsyn and itunes support or knew what it is I do. Thanks a lot for any advice you may have.

    RSS feed: http://enslavedbythebell.libsyn.com/rss

    I went and tweaked your workflow slightly.

    Try to send back you your feed now.

    Rob W

    libsyn

  • When I click on an RSS feed, I get this message. XML file does not appear to be any information of style associated with it... It works very well with Internet explore

    When I click on an RSS feed, I get this message. XML file does not appear to have any information of style associated with it. The same RSS feed works fine with internet explorer, any information would be helpful.
    Here are the first 3 lines from what I get

    < rss version = "2.0" >
    < String >
    < title >

    You open a new empty tab?

    Don't you see the text 'Click on the RSS buttonin the toolbar of navigation on this page?

    Start Firefox in Firefox to solve the issues in Safe Mode to check if one of the extensions or if hardware acceleration is the cause of the problem (switch to the DEFAULT theme: Firefox (Tools) > Add-ons > appearance/themes).

  • News Feeds Widget not get RSS news! Help! (Or stream is marked as read automatically?)

    I installed as a widget, the news application. I used to get a lot of food when I subscribed to a package before the upgrade to the latest Android 2.1. I added my own feeds to a few sites that I know publishes daily, if not hourly, feeds. They are never shown on the news wire. Well, it's what seems to happen: I was looking for right on my phone and I have not hit or something, but on this News Feed, it comes to show a new stream. I haven't touched my phone, it's just sitting on my desk as I type this. And then the new stream just disappeared and now it reads: no recent unread again. But if I had not looked at just the screen when she appeared, I knew that there was still food for animals!

    It seems that it is reading feeds and automatically mark them as read and so so I can not read or display them correctly. Is there some sort of setting? I tried to remove this widget and creating a new widget using a wrapped package of advances and is having the same problems. It will not display the items. I have the display items defined for the longest amount of time to SHOW ITEMS for: (currently at 1 month). This has not changed anything.

    So, how can I get it to show something else than this thing of ARTICLES no LUS RECENT NO he appears constantly? He used to work... it must be automatically marking them as read and their deposit without me even by visualizing... it sucks.

    Well, I did a full factory of my phone data reset. Totally wiped all data and configure my phone again in the start menu of motoblur throughout. I loaded my Motoblur account before (I tried once again with a fresh Motoblur account to see if that had an effect on it - none that I could say, so reuse the one I had should be no problem).

    I have reset to the essential, and I am happy to say my app News widget now works finally! He showed a lot of RSS feeds and that they disappear no more! Must have been a bug or something with my phone before that only a factory reset could fix. Or just coincidentally they fixed the News Feed App widget on the exact time as well as I did the reset!

    Unfortunately, even if all my programs work perfectly well and super fast now running, she was again resort to reset everything on my phone. I am so happy with this phone. If I could do an another phone update anytime soon in my contract, I would. But financially, I'm stuck with this phone at least next year, I can say.

    Now I just need to know if it would be useful to the Valley at the AT & T store main located in Walnut Creek, where I was mentioned by a tech to a backend at Berkeley who just formatted and reset my phone only one month ago exchanging my phone for a new brand. I couldn't do in the Berkeley store because it would take 3 days to replace, and I need a phone every day. The Walnut Creek store would be able to Exchange and replace the phone the same day. I don't know if it's a hardware problem or software comes to be really crappy.

    But thanks for all the advice and help. It seems that restarting usually is the answer to everything. I learned to work on PC for so long! Now I guess I need to find how to clean my SD card because I've already replaced the apps very minimal and did not want to format the card now. But that's another thread and bc, it's a whole other topic of discussion!

  • Problem with Knowledge Base detailed RSS feed

    Hello

    I've subscribed to the Feed detailed Knowledge Base via http://feeds.feedburner.com/vmwarekbfeed.

    Because the power source has moved around Jan, 14 I get the same items over and over again, every day.

    Statistics of Google Reader for the last 30 days, there are 309 new article / per week which is a lot more than before.

    Is it a problem with the power supply itself or with the tag "updated date" items change all the time?

    Any help is appreciated!

    See you soon,.

    Vincent.

    Sorry for all the problems with the RSS feed. We look for ways to solve this problem, as the diff鲥ntes involved pieces do not play well together.

    Here are some alternatives for you that you may want to consider:

    1. KB Digest is published every Monday with a list of all the new articles from the previous week.  The correct URL for RSS feed of this blog is here. The RSS feed of this blog works, we are committed
    2. If you're on Twitter, follow @VMwareCares. This account tweets per day for each new KB article.
  • On old laptop, I got a type of analysis with RSS feeds toolbar. Now have 18.0.2 and do not get to see what is later, all the time. How can I get RSS analysis?

    Is available or not for RSS bar analysis? He was a favorite of mine feature to stay connected without having to open a site on news or click on anything other than the title that interested me. If the analysis is no longer available, is there a page in order to get similar things to the old RSS feeds? Can it be done through FaceBook?

    The only RSS feature in Firefox's live bookmarks.

    For a news ticker, you've probably used an add-on like HeadlinesTicker.

    As far as I know, this is the only news ticker Add on available (another one, NewsBar seems to be obsolete and non-functional in the latest version of Firefox). However, there are several other RSS reader modules that display news in formats other than a news ticker.

    You can also subscribe to feeds through web sites as follows.

  • Has been approved - has blocked for now, and then unlocked - no more shows. RSS feed problem or what?

    See you soon,.

    I was in the last phase of the construction of my podcast site (http://fontoradio.fi).
    I wanted to send to iTunes in advance to make sure I can get it out here too, as soon as I publish my Web site.

    Everything went very well: my podcast has been approved, and the iTunes search tool found, with two episodes of test I had included in the RSS feeds (real episodes that are intended to be implemented later). Then, I wanted to make sure that nobody'd, as I had already begun Fonto Radio talking to friends etc.

    I published a new RSS feed (using the app charger), with ' block in iTunes: Yes "and behold, my podcast do not appear in iTunes. Excellent!

    After completing the site, I've made a new RSS yet, with ' block in iTunes: No. That was five days ago.
    Fonto Radio can not always be found on iTunes.

    Well if I choose 'send the podcast' drop iTunes and paste the feed URL (http://fontoradio.fi/FontoRadio.xmlhttp://fontoradio.fi/FontoRadio.xmlhttp://fontoradio.fi/FontoRadio.xmlhttp://fontoradio.fi/FontoRadio.xmlhttp://fontoradio.fi/FontoRadio.xmlhttp://fontoradio.fi/FontoRadio.xml) in the box, he gets up and I can listen to the trailer, the only published point/episode.

    What do you think of that cause?

    Thanks for any informed guesses or made in advance.
    Best,

    City

    The store normally does not accept feeds with episodes of test, so it is possible that you have been deleted for that reason - when you said it was available, it was in the iTunes Store, not only in the iTunes application? Have you received an email of acceptance by giving you the iTunes Store page? If it has been removed you should have received an e-mail saying so - check your spam trap.

    There is another question - your image podcast is too large to 3 889 x 3, 889px and 2.5 MB. With this image, I am surprised that you have been accepted in the first place.

    If you need create a new image, 1400 x 1400 minimum and maximum 3000 x 3000 and less than 500 KB. Then you need at least a good episode in the power supply.

    Then try to submit to https://phobos.apple.com/WebObjects/MZFinance.woa/wa/publishPodcast . If you receive a message saying that it's already been submitted you could try to change the name a bit (you can change it back once accepted).

    Otherwise, go to https://itunespodcasts.zendesk.com/hc/en-us/requests/new and click on the triangle to the right of the field "Choose a topic" - select "Reactivate feed" and proceed from there.

  • In support, forum, signed in, where can I associate with the questions I ask myself? Years back, could get the RSS feed for the question. Always available?

    Where can I associate with my questions about my account? The search for user name does not work. A few years back, you could subscribe to an RSS feed for a question, yours or others. Is - this past, if so, why? How can you save the question, without saving your question text in a document and copy and paste into search? Version of FF 19.0.2.

    Thank you.

    Your messages will now appear in your profile: https://support.mozilla.org/en-US/user/225440

    You can also use the old method of "My Contributions" link: https://support.mozilla.org/questions?filter=my-contributions

    Is that it?

  • Is it possible to implement the RSS FEED like IE to get photos instead of links

    On Internet Explorer when you pull up a RSS feed for photobucket it shows you a scrolling to the bottom of the list of the photo. Firefox gives you links which will take you to the page of the person. In time need me to follow a link, I can scroll through 25 photos on IE.

    Is there a way to fix this?

    Thank you

    Michelle

    Look through these extensions for an extension with the features that you want to add to Firefox.
    AMO - search RSS

  • How to cancel selection application RSS feed button?

    I checked the box that says use the application chosen for each RSS feed subscription. Unfortunately, the new version of Mail (Yosemite) does not FEED THAT like the previous version. now, I get an error message whenever I try to subscribe. How can I solve this problem. Thank you very much

    You can read the article of Web feeds in Firefox > Preferences > Applications

  • RSS feed of bookmark bar randomly displays only a shadow, no menu

    OK, I have a strange problem which just started occurring after a reload of the OS. When one look at my RSS feed pull-down in the bookmarks bar, they will often open 100% transparent, the only thing visible is the shadow that surrounds it. The menu works always; I can even click on things and it will bring to the top of the page, but as I don't see what it is, I have no idea what I'm clicking. I can get it visible again by the closing and reopening of the drop-down list (sometimes it takes a couple tent).

    Nothing has changed in my profile of browser since I recharged last windows. I reloaded Windows (64-bit 7) once because my secondary HARD drive controller crashed on me and I rebooted windows thinking there is a faulty driver stuck in the operating system (that and get rid of the extra junk during the past years), but later found the motherboard was bad, so I replaced and recharged again (primary is 2 x SSD Raid 0). I am now under this second cooldown and loaded my profile in the same way as before, and I'm getting the question.

    To save and load the profile I did the following: FireFox menu > help > troubleshooting information > Show (profile folder) and then closed FF and copied all the content of the folder in a backup directory. Reloading of the profile is the same process, but copy the files in the profile folder after the closure of FF. I did this on the first reload as well and had no problem, but for some reason any I'm flowing in it now. Seems to happen more in loads of heavy file (such as copying to USB HDD RAID of SSD) transfer. Not really sure if this is related or not.

    Anyway, no idea why this might be implemented?

    Found the problem after messing around with the personas for a bit. It seems that one I used had got corrupted somehow. I have removed the theme then downloaded from the site of personas, and it seems to have solved the problem. Don't know why he affected others while...

    He finds as he tried suggestion of Cor - el once again, so that marked as useful.

  • Unable to send rss feeds

    I can't submit my podcast in iTunes. When I get my Podcast feed URL I get an error saying "we currently live technical difficulties. Please try again later. "This has been the case for two days, could someone please help.

    I contacted apple support twice and they asked me to post a question here

    my RSS feed is http://feeds.feedburner.com/ComicBookNerdNationPodcast

    Please help me

    Hi Rameixclaude,

    You've seen

    The Apple make a Podcast page? There are a lot of useful info here: http://www.apple.com/itunes/podcasts/specs.html

    You can validate your workflow at these locations:

    http://podba.se/validate/

    http://FeedValidator.org/check.cgi?URL=http%3A%2f%2Ffeeds.feedburner.com%2FComic BookNerdNationPodcast

    It seems that there are problems with your image, and so the iTunes Store is having a technical problem with your workflow. I show this in the code:

    [URL = http://s446.photobucket.com/user/ComicBookNerdNation/media/CBNN%20iTunes%20 Icon_zpsuxj6dr0e.jpg.html] "[[IMG] http://i446.photobucket.com/albums/qq185/ComicBoo kNerdNation/CBNN%20iTunes%20Icon_zpsuxj6dr0e.jpg[/IMG][/URL]" / >

    The supply must display your image as:

    http://www.example.com/image.jpg"/ >

    Try changing:

    1. what makes your image more 1400 x 1400 (3000 x 3000 to 72 dpi, RGB, JPG tends to be popular).

    2. remove the [URL and [IMG of portions of your link to the image. One of the foods above validators allows re - test.

    3 host your image on a Web site that is not redirect as PhotoBucket. Some podcasters have problems with Photobucket. When people link to an image to Photobucket, the site does not display the image - instead, people are redirected to a Web page that contains the image, with ads that surround it.

    -Fan

  • I lost my new RSS feed MSNBC.

    How to restore this service. I don't know how I got to lose except if removed a NFB the technitions, but in any case, I want to get it back please.

    Hi, Rosemary,

    You can go through the steps from the thread that talks about a similar problem and check if that helps.

    Here is another article on RSS feeds. Take a look and check if that helps. You can also follow the steps in this article and check if it helps.

    In Internet Explorer-> Tools menu-> options-> content tab Internet-> under feeds and Web slices, click the button "settings". Check the box before "Automatically check the flow and components Web Slice for updates". On the ' all: ' drop-down to select the desired frequency field.

    Hope this helps and let us know if you need more assistance. We will be happy to help you.

  • Conntection time-out in the workflow RSS feeds?

    Hi all

    JDev worm: 11.1.1.4.0

    I am the new bee on webcenter, I'm trying to get the RSS feed on the page jspx

    I used the display Rss taskflow and URL used: http://feeds.reuters.com/reuters/topNews

    I get a msg of connection timeout...

    How to solve this problem?

    Thank you
    Guillet

    You are behind a proxy server? It is possible that when you use a proxy server, you must configure the weblogic server so that he knows how to connect to the internet by using the proxy server.

Maybe you are looking for

  • Equium M40x-189 and BIOS update

    There are updates of bios for my laptop, and so I thought I would try a flash update. I can only find the Trad version and not the flash version of Win.the problem is that the traditional flash update file asks you to create a bootable cd for the upd

  • Issue of Netflix yoga 8 in section 4.4.2

    Anyone having problems watching on Netflix after update to 4.4.2 on 8 of Yoga? I get messed up pixels and green/purple pixels on the screen now, everytime I watch a video since the update, which makes it very bad. Oh, and the volume buttons are confu

  • How can I download producer?

    How can I download producer when you use iBooks author and iTunes Connect to publish my recipe book for free? I created an account, completely separate from my normal Mac ID after reading some of the tips in these forums. Now I can progress through t

  • Wireless routers? Is anything the most RECENT/FASTER coming out soon?

    Hello I am looking to buy a new router. We do a lot of games on the internet and streaming video in a large House, usually at the same time with multiple devices. I bought a Cisco EA6500 almost 2 years ago and it seems to slow down when several peopl

  • How to remove DNS queries for banned sites?

    Hello I'm looking to create a certain number of signatures to DNS queries for banned sites, the only way I've implemented successfully is to create a signature (string UDP), so he abandons all traffic UDP 53 containing the banned site regex string. I