WHICH IS BETTER JDBC OR SQLJ

HI
CAN SOMEBODY EXPLAIN TO ME THE DIFFERENCES BETWEEN JDBC AND SQLJ AND WHICH IS BETTER???
THANK YOU

Well, SQLJ has been desupported in 10g, so I would strongly hesitate to do new development there.
Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC

Similar Messages

  • Which is better JDBC or JTA with DAO pattern

    Hi,
    I have developed DAO's for each of the tables in MySql database having around 10 tables, should I go for JTA or JDBC for transaction handling ?
    What is a better approach for transactions spanning multiple tables like for example deleting a master record must delete all child records? Accessing data from 2 or more tables with select statements?
    Any examples on the same?

    If it's all in the same database then it's still local.
    Distributed transactions use a transaction manager (TM) and things called resource managers (RM) to manage transaction. The TM co-ordinates with all the RMs and the RMs use local transactions to communicate with whatever transactional system you are using. If you only have one database you only have one RM - in which case the TM is co-ordinating the RM with itself. If this is the case you don't need the TM and the RM can be bypassed by just configuring the transaction locally.
    This still applies if you are using two separate systems that are not involved in the same transaction.
    Essentially it's down to the different methods you use to get a connection - each connection method (not call!) will have it's own RM.

  • Which is better ODBC or JDBC

    dear all,
    after upgrading most of our servers from cf5 to CFMX7.1, it
    is now time to start working on some performance strategies for the
    upgrades. currently we went with the ODBC connector in CFMX for
    testing purposes. one of our server will occasionally lose the odbc
    and we have to reboot the server to get it rolling again.
    this leads up to the question of which is better for
    performace (speed, less process inducive) and realiability. ODBC or
    JDBC with CFMX7.1
    thanx
    sean

    I would concur ... as CF is java based, it will run better
    with JDBC rather than having to interpret a bridge between the 2.
    There are a couple of very remote instances where ODBC may be
    required, but you will have much better results with JDBC.

  • JDBC or SQLJ

    Hi guys,
    Can someone please tell me which one should I use, JDBC or SQLJ when writing the programs that connect to the database and do inserts/updates/deletes and retrive rows from the database based on SQL queries. Please state what would be plus point of choosing one over the other. I vaguley remember reading somewhere that SQLJ is better when the application that uses it, is going to issue mostly static queries to the database. However, if the application is going to use dynamic queries, then JDBC is better. Is this correct?
    Are there any other reasons? Also, in the same program both can be used simultaneously, correct? Thank you!

    I did check out SQLJ simply out of curiosity, but I don't think SQLJ has any practical use for enterprise software (well, that is what I do and I will speak from that point of view).
    Think about this. When you develop a software application, you want to minimize the chance of going back to fix anything, and recompile and redeploy as much as humanly possible. If your SQL statements are embedded inside the application's code, you increase the chance to have to make changes.
    JDBC is a better route. There are two ways to do that:
    1. Do a simple client-server set up. Put all your SQL queries and data manipulation on the stored procedures. Stored procedures are precompiled and run on the server, therefore increase performance (it has to be faster than SQLJ). All you have to do is to call these stored procedures from your Java code with whatever parameters that you have to pass.
    2. If you want to do it right, multi-tiers is the way to go IMHO. Put all the select/update/insert simple SQL statements in the stored procedures. But maintain the business logics, business rules, and calculation in the middle tier.
    As I have said, I develop enterprise software that processes millions of records in short period of time. It might be different in other situation. But I still think that JDBC is better than SQLJ for practical application.
    Just my $0.02.

  • What is faster JDBC or SQLJ ?

    hi
    i am writing a java stored procedure in db2.
    i have to process nearly a million reocrds. For ech record i have to do atleast 15 inserts/updates to the database.
    what would be better to use JDBC or SQLJ(static sql) in terns of speed

    hi
    i am writing a java stored procedure in db2.
    i have to process nearly a million reocrds. For ech
    record i have to do atleast 15 inserts/updates to the
    database.
    what would be better to use JDBC or SQLJ(static sql)
    in terns of speedLike all good performance questions... it depends. If I were going to process 1 million records and do 15 million insert/updates with the results, I would look first at using the database vendors native utilities. It may be faster to read the million records with Java and write 15 million records into a flat file in the format expected by a native load utility. Then use the native load utility to do the insert/ updates. These load utilities can be 100's of times faster than anything that can be written in Java at this time.
    If you are set on using Java, then... it depends. When using JDBC you should use Batch update functionality, this can speed up insert/update activity by 10x+, if you do it correctly (making sure that you select the appropriate batch size). Prepared Statements provide the least external overhead because the database engine only needs to parse the SQL statement a single time. However you are providing less information to the database optimizer and this could result in worse performance for update processing. Insert activity will not be negatively, and should be positively effected by using a prepared statement because there is no query logic. I haven't written a Java DB2 stored procedure, but I am assuming that you have normal JDBC functionalty available to you.
    I'm not sure exactly what SQLJ does for you. It sounds like it is similar to a Prepared Statement (static vs. dynamic SQL). Perhaps others who have used SQLJ can add some of their knowledge.
    Once again, I would highly recommend looking at alternative utility processing as your first choice, some form of hybrid Java Stored procedure with a load Utility as a second choice and Java stored procedure only, as your last choice. Remember that volumes tend to increase so if this is an on going process you want to allow for 2 or 3 million records for the future.
    Joel

  • Which is better? JDO or Java Persistance API?

    Hi folks
    I'm trying to build an app on Google's cloud service.
    Looking into this ( [http://code.google.com/appengine/docs/java/overview.html|http://code.google.com/appengine/docs/java/overview.html]), it tells me that for java projects there are 2 possibilities for persistance - JDO , and Java Persistance. Does anyone have any advice on which is better and/or easier? Also, if anyone has a small example they could post, that would be very useful too.
    this isn't exactly a JDBC question, and maybe this should be posted somewhere else? If so please tell me where I should be asking this question.
    Thanks!
    -Tom

    I personally find Java Persistence to be easy to use and it works just fine.
    I can't say if you would agree. You'll just have to judge that for yourself, which means: put some effort into trying it out. I'd start by not requesting small examples in a forum, but by actually looking for them yourself using your search engine of choice.

  • Connection from jdbc or sqlj using operating system authentication

    Is it possible to use the operating system authentication to connect to oracle which is on the same box from jdbc or sqlj??
    Any help is appreciated

    You can logon using external credentials with the oci driver by passing in null's as username and password.

  • Which is better to use: BEx query or Web Application as an iView in portal?

    Hi gurus!
    Are there any experienced opinions, which is better - publish a BEx query in portal or publish a BEx Web Application in portal? Is it easier to alter the layout attributes etc. if I create a BEx Web Application first before publishing?
    What is the way of fixing for example filter item height if I publish BEx query in portal - is there a Web Application that it uses anyhow which I can fix? Or can I use in that case iView -properties in portal?
    Thankful for advice
    Sari

    ok, means i can use jsp:useBean tag for all my
    classes that are not actually bean. so it will be
    instantiated at run time and provide efficiency .No. Jsp:useBean is used for java bean components.
    >
    but when should i use import statement in my jsp and
    it happen at translation time so will it create any
    type of burden for my code if i import multiple
    classes.For non-java beans, you need to import the classes, period.
    It's not a burden, it's a necessity.

  • Which is better for performance Azure SQL Database or SQL Server in Azure VM?

    Hi,
    We are building an ASP.NET app that will be running on Microsoft Cloud which I think is the new name for Windows Azure. We're expecting this app to have many simultaneous users and want to make sure that we provide excellent performance to end users.
    Here are our main concerns/desires:
    Performance is paramount. Fast response times are very very important
    We want to have as little to do with platform maintenance as possible e.g. managing OS or SQL Server updates, etc.
    We are trying to use "out-of-the-box" standard features.
    With that said, which option would give us the best possible database performance: a SQL Server instance running in a VM on Azure or SQL Server Database as a fully managed service?
    Thanks, Sam

    hello,
    SQL Database using shared resources on the Microsft data centre. Microsoft balance the resource usage of SQL Database so that no one application continuously dominates any resource.You can try the 
    Premium Preview
    for Windows Azure SQL Database which offers better performance by guaranteeing a fixed amount of dedicated resources for a database.
    If you using SQL Server instance running in a VM, you control the operating system and database configuration. And the
    performance of the database depends on many factors such as the size of a virtual machine, and the configuration of the data disks.
    Reference:
    Choosing between SQL Server in Windows Azure VM & Windows Azure SQL Database
    Regards,
    Fanny Liu
    If you have any feedback on our support, please click here. 
    Fanny Liu
    TechNet Community Support

  • Which is better??????

    which is better?Dam really confused which speaker to buy??
    i currently have a creative m2600.but am not getting enough performance or that feel while watching movies like avatar,step up 3 etc......so am planning to buy a 5.1.......not planning but i have decided to buy a 5.1....so..
    which is better? the 6160 or 6060 or 6100.
    which of these will provide me relly great exprience while playing games and most importantly while whatching hd movies and while listening to music.......
    and other than this what i have to ask is...what is this "db" in speakers. i mean while looking at a speaker specs we can see it..like 65db,85db,75db..etc........
    and when i compared specs of the three speakers i mentioned above i saw that the 6160 has low "db"........why is that?

    The specs is just a guide, you won't be able to tell the slight difference in db using just your ears. Besides, it is just a comparison between the level of a music to the level of background noise, it does not necessary mean which speaker sounds better. If possible, please make a trip to your local electronics store and try out the speakers system yourself.

  • Which is better, Photoshop or Corel?

    Which is better, Photoshop or Corel? I am finding the best one to use for my website [link removed]. Let me know your opinion. Tks all.

    Thank you! I am trying to find the best one for the site [Link removed].
    I used to use Corel before, but now, I am trying to use Photoshop.
    Tk you anyway
    [Removed link]
    Message was edited by: sinious

  • Which is better software for brochures and PDF forms ? Photoshop or InDesign ?

    Which is better software for brochures and PDF forms ? Photoshop or InDesign ? and why ?

    If you are going to be making a lot of brochures, with photos, you probably want both. Photoshop to edit the photos, and InDesign to assemble and layout images with text.

  • Which is better an android or apple

    Which is better getting an android smart phone or an Apple I Phone?

    As the poster Horses 547 said its a matter of personal preference. However I own and use both. Printing via air print is smooth and easy on an iphone. Printing on a android phone is iffy and tedious and you will have to find an app to print since there is no native app to do so. I purchased http://www.printhand.com which costs around $12 from the app store. but it is in my opinion the best printing app out there for android. I use it on my android tablet as well and its great. This company is the maker of the print app on iphones.
    The iphone is a little harder to put your own ringtone on the device. However very easy from the Itunes you put on your computer and hook into.
    Another thing an iphone does is if you use their cloud service or pay for a song it is available on all your ios devices. Iphone, ipad, or ipod or up to five computers registered through itunes on those computers.
    Google play music also can sync with all your android devices.
    Iphone don't have external Micro SD card slots, so the storage on the phone is all you have.
    Iphones use imessage which does not count against your text allotment  to another iphone or ipad user. it send regular text to non iphone users.
    Another thing is Face Time but I found a better program called oovoo at http://www.oovoo.com or in the Google Play Store for free.
    Iphones are paper thin but I have an android that has a larger view area and is also paper thin and light. Depending on the android phone it may have a removable battery, whereas iphones are sealed as are some new androids. I have found the sound for music better on my iphone, and videos are crystal clear. Again on some better androids the music and video is comparable .
    There is really not many differences but it up to the user.
    One last good thing is iphones are updated via Apple, no long waits for OS updates like is done with Android devices, and android devices on Verizon.

  • Which is better for doing animation? Flash 4, 5, MX, CS, or others?

    Which is better for doing animation? Flash 4, 5, MX, CS, or
    others?
    I am used to using brush function more conveniently in Flash
    4 than the other versions I ve tried. However, Flash 4 doesn't have
    pen tool.
    Free News Reader
    http://put.hk
    http://put.hk/reader/forums.macromedia.com/macromedia.flash.html

    1Evan2Wing3 wrote:
    > Which is better for doing animation? Flash 4, 5, MX, CS,
    or others?
    >
    > I am used to using brush function more conveniently in
    Flash 4 than the other versions I ve tried. However, Flash 4
    doesn't have pen tool.
    all pretty identical tho I would go with cs, just because I
    like the GUI much
    more than other versions...
    Best Regards
    Urami
    "Never play Leap-Frog with a Unicorn."
    <urami>
    If you want to mail me - DO NOT LAUGH AT MY ADDRESS
    </urami>

  • Which is better for bulk message scenario in sap xi RFC or Proxy

    which is better for bulk message scenario in ( RFC or Proxy ) ?
    Edited by: prabhatxi on Aug 6, 2010 4:44 PM

    Proxy will alwaays be better option in this case, as it is adapter less framework, and communication happens directly with XI central integration engine. So it is always fast communication and gives good performance.
    But still you should consider other factors, you may consider using RFC as well, as sometime we go for RFC/IDOC as this are the standard interfaces already available rather than creating structure...
    May be you can share more info on what type/volume data are you planning to send via XI?
    Hope this cleart your doubt..
    Divyesh

Maybe you are looking for