1

Currently I am trying to run an existing java application on a Windows Mobile 6.1 device. The java application had been developed for server side and uses JDBC. My problem is that the Java application uses the java.sql.DriverManager which is not supported either by J9 runtime or by any CDLC/CDC implementation.

After doing a lot of research it seems that there is not a standard way to do that. The JSR 169 does not support this class as well.

So, I was wondering whether any of you have similar problems and if you have to mention any appropriate software stack that basically support the java.sql.* package on mobile devices. It seems that the specifications do not support this and the only way to do it is basically by hacking it up...

thanks in advance

bharath
  • 14,283
  • 16
  • 57
  • 95
dprapas
  • 25
  • 7
  • If you edit your question and provide some more details about your problem, I'd be happy to help you work through it. – Brandon Jan 31 '11 at 16:33

2 Answers2

1

There is no official JDBC support for CLDC-based environments. There is a JDBC optional package for CDC-based environments.

Database support for CLDC/MIDP is very sketchy. I see there's one here:

http://developer.mimer.com/platforms/productinfo_19.htm

but that's probably not what you want.

I think what you'll have to do is roll your own web service based system where you interact with Java code running in a web server, acting as your proxy for JDBC communication to the database.

Eric Giguere
  • 3,495
  • 15
  • 11
  • Any idea on what kind of devices can I run the CDC environment. I am using a Motorola MC75 device with Windows Mobile 6.1. I've managed to execute JDBC and my Java application using MySaifu JVM but I noticed CPU overloading. I would like to test also a CDC environment to see whether the CPU problem is due to MySaifu or the java application. Any ideas are highly welcome... – dprapas Jan 28 '11 at 22:51
  • There's very little support out there for the CDC. Not sure what else you could do, maybe the IBM J9... – Eric Giguere Jan 29 '11 at 04:01
  • The JSR 169 jar adds support for JDBC to both configurations. – Brandon Feb 01 '11 at 18:23
  • Incorrect. The formal name of JSR 169 is "JDBC Optional Package for CDC/Foundation Profile". No CLDC support because it depends on classes not in the CLDC. – Eric Giguere Feb 01 '11 at 19:05
-1

I don't know how to use DriverManager in either configuration.

If you want to use JDBC without too much work, you can switch to DataSource to get your connections. (Using the JSR169 jar).

Brandon
  • 2,900
  • 1
  • 23
  • 36