Character conversion issue? - ORDS, SODA & JSON in the Database

This is probably in the borderland between APEX 4.0 and the APEX Listener, so bear with me :-)
If I create or edit a row in a Websheet data grid, Norwegian characters æ, ø and å gets scrambled to "æ", "ø" and "Ã¥". This only occurs when going through the APEX Listener. If I bypass the listener and use the EPG, all works fine. I have not had this issue with "normal" APEX application forms. Inline editing in the Websheet data grid works with the norwegian special characters, it only fails in the insert/update form.
Is this a listener bug or a Websheet issue? Or something completely different?
APEX Listener:
APP SRV: Glassfish 3.0.1
Browser: IE 8, FF 3.5, Chrome 5.0 (All set with Norwegian (no) as primary language)

You might want to look into {message:id=3847395}, this helped me.

We think we have a fix for this and are testing it now internally.

That is good news. Websheets are pretty unusable to us with that particular issue.
I see where the solution is going, but I'd rather be without that kind of work around :-)
Best regards,

haavard wrote:
I see where the solution is going, but I'd rather be without that kind of work around :-)for sure, :) and if Kris has a different solution in the pipe, I'd be happy to.


Need help with Locale or language encoding

I'm not sure about the right solution for my problem, but here's the problem:
I'm from Israel, and I write some jdbc code using Oracle 10 server. (Oracle version isn't important, it used to happen also with Oracle 8).
The problem is, that when exceptions occur, Oracle will return a string like ????.???????? since it tries to convert it to my local settings, and not displaying the message in English.
I need to display sql exceptions in a dialog so the support team can deal with data problems.
The dialog doesn't display the messages correctly (not with question marks, though, but still unreadable).
My solution for the time being is to copy the message to the clippboard and let my user search the web or a translation program he has for the correct encoding.
I tried both setting the Locale to US using JOptionPane.setDefaultLocale(Locale.US) and I also tried the hebrew local (maybe the exception content will not be translated), but ti didn't help, as Oracle allready translated the messages for me.
I guess it's the use of encoding schemes that will solve that problem, but I don't know how to do that in my application.
I'm using Intellij and my console also displays unreadable data,
I didn't find how to change it in my IDE's settings.
How can I display the data correctly?
Run Oracle with an English locale? Or this that outside your control? 
I can't change anything in Oracle.
However, the problem is solved.
We used to use the Oracle driver for Oracle 8 with all of our systems,
but now we upgraded it to the driver compatible with Oracle 10,
and it returns values correctly.
BTW, I don't see it as a good solution, since I didn't realy solve the problem, I only bypassed it.
When I'll encounter it again with a non Oracle produce that doesn't support hebrew, I'll get stuck again.
But for now, it'll do.
Thanks anyway.

What's DecodeInterceptor

Hi All,
Whenever I use Tomcat 3.3, it always gives me this message:
2002-02-15 16:44:16 - DecodeInterceptor: Charset from session ISO-8859-1
what does this mean? do I miss some complementary classes?
thank you. 
I've noticed it too and I disabled it. It is a module that is started up when you start Tomcat. If you remove the reference to it from the server.xml file, it will not start up. The class itself is found at:
I haven't looked at it closely but I'm guessing it tries to intercept form data and determine the encoding. Then it does some kind of conversion. It was giving me trouble because I have an application that accepts Japanese text from a form and tries to detect the encoding and convert it to EUC_JP. My custom encoding detector works great but the DecodeInterceptor was getting in the middle of things and causing troubles for me. Basically, it would turn my Japanese into gibberish. So I disabled DecodeInterceptor and everything worked great. I've noticed in Tomcat 4.0.1 that it doesn't appear to be included. If it is, it isn't messing me up anymore because I haven't had to disable it.
Hope this helps,

Strange Problem With Extra Spaces

My development staff is experiencing a very strange problem with our JSP pages which display the values from a JDBC result set. We have two environments here: development and production. We have been creating pages in development which work out fine in our development environment. But when we move the page into production, each value which results from the ResultSet getString() method is having multiple blank spaces appended to the end of the value. So, for example, a 5 digit zip code field is really showing up with a length of 8 or 9 because there are extra spaces added to the end of the value.
We are able to work around this problem by using the trim() method, but this is getting quite tedious to do to every single page in the site. It is very annoying because the problem does not exist in the development environment.
So you figure there must be a difference in our development and production environments. But there really isn't. Here is the details for both environments:
OS: Windows NT 4.0
Web Server: Apache with Tomcat setup as a plugin
Database: Sybase ASA 6.0.3
JDK: 1.3
Apache and Tomcat were installed from the same download on both servers. Sybase was installed from the same CD on both servers - and the JDBC Driver (SybDriver) was copied from one server to the next.
Sorry for the long explanation - but does anyone have any idea what could be occurring? Why are the extra spaces being appended to the production pages and not the development pages?
As always, thanks in advance for any suggestions!
-- Chris 
I'd guess that your production database is set to pad out fields to it's maximum size so it's the database adding the extra spaces. Is the field a varchar(n) in dev and char(n) in production?
Hi carrich1,
I think addyj could be right.
We have to check the column defnition at the table level
-- Paul.
If nothing else you could just use the trim() function to get rid of the excess spaces at the end.
zipcode = zipcode.trim();
zipcode = rs.getString("pa_zipcode").trim();
either will work. 
Hi rclover34,
The Staff knows that. But they to see why. So we suggest to check the column definition at the Table level.
-- Paul. 
I guess I should have read more carefully.
Paul and addyj,
Thank you for the suggestion. I checked with the DBA's and they said that both databases (and all of their objects) were created from the same DDL scripts. The two databases are identical. So I don't think our problem lies there. Any more suggestions though are greatly appreciated.
Thanks again,
Hi C,
Can you have a simple check for the value stored in that column (zip)
to see how it is.
Is it 99999bbbbb where b=space
or is it 99999
Hi Chris,
1. Can you a quick sql for the zip field:
select len(zip) from ZIPTable
to see what is the size of zip - is it 5 or 9
2. If it is 5, then something in the code is not quite right.
Hello Paul,
Thank you for taking the time to analyze this case.
The data in the system comes from two different sources. The first source is a nightly feed from a legacy system. The second source is user input via the JSP application. The records that were inserted from the nightly feed have an accurate length() value (meaning there is no untrimmed spaces trailing along.) But the values coming in from the application have extra spaces appended to them. In the development environment, however, both sources provide properly trimmed data.
If I enter an 8 character last name into the web form in the production app, the value which ends up in the database upon submission will have 2 to 3 extra spaces. I know that this sounds strange - and believe me, it is boggling everyone here. I suspect this problem has to do with the Tomcat installation - even though it was installed identically in each server.
I think we are just going to have live with using the trim() for every database submission. As always, thank you for the help, and all ideas are always welcome.
-- Chris

Early feedback (and PostgreSQL connectivity)

Great tool, looks very promising to me.
Disregarding warnings about supported databases, i tried
postgreSQL connectivity and was very pleased with the
results. It just works (So far at least)
I hope that the finished product is priced within the reach
of our small development shop.
Roberto de Iriarte 
Found a small bug regarding the property inspector.
Trying to explore an object properties from the document outline pane (with right_click-> properties) does not work. It does however from the design pane
were you able to populate a drop down from from your db? I couldn't seem to get that to work. I could add a datasource okay, but could never get it to allow me to pick the columns I wanted for my name / value pairs. 
couldn't add an Informix datasource .
It seems that it could not load the Driver... 
my mistake... typo error...sorry about that 
Assembling the application works OK, the deployment fails (No wonder as postgreSQL connectivity is unsupported)
The error is "Real JNDI name cannot be empty for jdbc/DATABASE_NAME" (As seen in the server log)
I will look into it but it seems solvable (Some manual tweaking of the deployment descriptor should do it)
Will report back as soon as i find a workaround.
Oops, my early post was regarding the population of a combo box from a table.
Will try to debug it later.
Did any one solve the problem for connecting and populating in dropdown menu from postgres? 
I wuould also like to add that in the production release in July it still does not work.
No datasets or values are generated. 
Anything yet on this postgres problem? I'm using the type3 jdbc drivers with PG yet I don't get anything on the 'fill list from database' dialog - it's completely blank. I''m using the pg type 3 jdbc driver (pg74 .1jdbc3.jar) and all other db connectivity seems to work fine. 
Me too. Is this problem in the JDBC driver? There is nothing on please say something...arrrrrrrrrrrrh. 
This problem still exists with the latest Postgres 8.00 Database and the JavaStudio Update 6.
The "Fill the list" dialog remains empty and only the OK, Cancel, Apply, Help buttons appear. 
Most likely this is a driver issue.
The driver may not be fully JDBC 3.0 compliant
There is a mailing list where you could find out for sure.
Why does it work for some and not other. I also have the problem not being able to bind to postgresql. We have an system that I would like to connect to from JSC but if the DB part does not work I can not use it. Please give us some feedback as some say it works and others say not

What URL is needed to execute procedure located in another schema?

I've been using EPG successfully for a year.
I'm installing Apex Listener 1.1.3 to hit an instance.
Both are on Oracle Linux 6.
I didn't block or allow anyting in the security part of the listener.
This URL works:
ops.hello_world(); -- Granted execute to APEX_PUBLIC_USER
I cannot find a URL to call ops.hello_world directly.
I expected this to work:
I've been on the forum and googling without luck. I'm stuck.
I also notice I can do this and it works:
create synonym hello_world for ops.hello_world.
I am able to pass parameters, too.
Assuming that you do this:
connect testuser/testuserpassword
  htp.print('  <head><title>Hello World</title></head>');
  htp.print('  <body><h1>Hello World</h1></body>');
GRANT EXECUTE ON hello_world TO APEX_PUBLIC_USER;Then the URL ought to be:
Now, admittedly there was once a bug in the APEX Listener that didn't do this correctly, but to the best of my knowledge, that bug was fixed in the latest version. 
Alas, that is exactly what I'm trying to do. And it doesn't work (for me, at least). 
What kind of error message do you receive? Any log entry in APEX Listener's application log?
I did a re-install and the APEX_PUBLIC_USER is now able to see a procedure in another schema.
You helped me quite a bit by implicitly indicating that what I was trying to do should work. With new technology like this, you don't know exactly what is allowed. Since this thing is called the "Apex Listener", maybe hitting a package/procedure in another schema isn't supported.
I think I'm seeing that this isn't enough to hit a new package/procedure:
1. Create a new package/procedure.
2. Grant execute on "new package" to APEX_PUBLIC_USER;
3. Hit the URL for the "new package/procedure".
I think I'm seeing that I have to bounce the listener for the URL to work. Can you confirm this or indicate I'm wrong.
ps: You answered the original post so I flagged this answered. Your support is much appreciated. 
With new technology like this, you don't know exactly what is allowed. Since this thing is called the "Apex Listener", maybe hitting a package/procedure in another schema isn't supported.It is supported, as you can configure APEX Listener do use a different database user than the one used for APEX (which is usually the APEX_PUBLIC_USER). Though this is not the main target for the APEX Listener, it'll work. If you want to run both APEX and your custom stuff you'll either have to have one user (preferably APEX_PUBLIC_USER) that has grants to execute both, or you have to deploy APEX Listener multiple times - once for APEX and once for every custom schema you want to make accessible. This is pretty similar to the DAD semantics that exist for mod_plsql or the Embedded PL/SQL Gateway in XDB HTTP Server.
P.S.: Please consider marking helpful or correct answers accordingly to help other users searching for a similar issue to spot relevant posts easily. Thanks! 
One last thing and I'll close this one out.
I think I'm seeing that I have to bounce the listener for the URL to work.
Can you confirm this or indicate I'm wrong.In an attempt to be clearer, I'm seeing this pattern and I'd like confirmation that I'm not missing something.
I create procedure ops.hello1.
grant execute on hello1 to apex_public_user;
I start the listener.
The listener returns results from ops.hello1.
I create a new procedure ops.hello2.
grant execute on hello2 to apex_public_user;
The listener does NOT return results from ops.hello2.
I stop and restart the listener.
The listener now does return results from ops.hello2.
It would appear that the listener must be restarted to execute procedures made visible to APEX_PUBLIC_USER after the listener was started. It is as if the listener starts, queries the dictionary, and limits what you can call based on privileges in place at start time.
Could you confirm this is how it works? It seems odd to me.
Hi Kurt,
unfortunately, you are right - this is how things work. The reason for this seems to be the metadata caching done by APEX Listener. See this thread for a discussion on that issue: {thread:id=2290910} (you might want to start with the last posts to avoid to read the clumsy trouble shooting attempts that got us there...)
Thanks for the definitive reply. It would be nice if some of these nuances were documented, but I realize that isn't exactly your department!
Hello Kurt,
you're welcome! The major use cases (hosting APEX and using RESTful features) are documented pretty well by now. I think the documentation gets better from release to release, and I have the notion that questions that arise here in OTN forum are incorporated. Probably the next release will include additional features to support migrating from mod_plsql and the documentation for that use case will be enhanced as well. But as always, that's just rumors as long as that next release is not availabe.
Please consider to mark helpful or correct answers in this thread accordingly, so other users searching for a similar issue will be able to spot relevant posts easily.