How can I use sequences in BC4J

Hello!
I read in BC4J documentation about how can I use database sequences to generate next value with BC4J. My question is:
If I don't want to use DB seq what can I do? We have DBSequence class. I look into it and see there not only a DB seq allowed.
Can anybody help me? I don't want to use DB sequences.

Don't quite understand the question. If you don't want to use DB sequences, then just override the create() method in your entity object and use call a setter method to set the attribute ID to what you want if you want to do this in an "eager" way that the user would immediately see in a newly-created row...
...or you can write code in an overridden prepareForDML method if you want to set a value for one or more attributes just before the changes are posted to the database.

Similar Messages

  • How can i use "sequence"

    hi
    I have created a sequence as the following:
    create sequence id_seq start with 1 ,increment by 1;
    I create a table as the following code:
    create table xmltab(id number primary key,xml_content varchar2(4000));
    After this, In jdev9i,I try to use the id_seq by the following code:
    Connection con=getConnection();
    PreparedStatement pstmt =
    con.prepareStatement ("insert into xmltab (id, xml_content) values (?, ?)");
    pstmt.setInt(1,id_seq.NEXTVAL);
    pstmt.setString(2,tempBuffer.toString());
    pstmt.execute();
    con.commit();
    pstmt.close();
    con.close();
    It is obvious that a error is occured :Error(933,22): variable id_seq not found in class ***
    How can succeed in using sequence?

    hi langyun ,
    it should be
    PreparedStatement pstmt =
    con.prepareStatement ("insert into xmltab (id, xml_content) values (id_seq.nextval, ?)");
    pstmt.setString(1,tempBuffer.toString());
    Sequence is a database object and cannot be accessed as a java object.
    so it has to be execute as a sql command.
    Regards
    Elango.

  • How can I use After Effects filters on a whole sequence without getting stuck in After Effects?

    It appears that, with the options that are visible to the user, Dynamic Link only goes one-way and can't make round trips from Premiere Pro to After Effects and back again.  If I send a sequence to After Effects, that part works fine and I can do what I want and save the comp.  However, even though the comp appears as an asset in Premiere Pro, I am not allowed to do anything with it.  If I try to drag it to a new sequence, it just says no.  If I click "Create Sequence from Clip" it creates an empty sequence.
    So how can I use After Effects on whole sequences/tracks instead of just on a clip-by-clip-by-clip-by-clip-by-clip basis?  is this possible?  For instance, if I have a whole sequence where I've neutralized the white balance, I might want to apply a warming filter to the whole thing as a unit.  That would be really painful with even a few clips to keep doing that again and again, and if you want to modify it slightly you have to do it over and over.  If there is a way to do that through Dynamic Link through some hidden option, what happens with the audio?  Would I have to cut it out of the lower sequence and paste it into the higher sequence with the After Effects comp as a video track?

    I'm not an Adoby guy, hence you may ignore my reply, but Adobe Dynamic Link is obviously not just one way ticket and in most cases works just fine.
    You have already been explained by J-MS and tclark513 how to properly use it and which pitfalls may occur.
    So as to apply an effect onto a whole sequence or a group of clips you need to either nest them in PrPro or pre-compose them in AE. Then just apply an effect (or several ones) onto that composition.
    So, if you nest clips in PrPro, select your nested sequence in the timeline, right-click and choose 'Replace with After Effects Composition'. Done! Your dynamically linked AE composition is in the right place in your timeline and in your Project panel as well. If you can not treat it as an ordinary footage, there are obviously some mistakes in your workflow. 
    If you didn't nest your sequence or a group of clips in PrPro before replacing them with AE composition, you may easily do it within AE. Just select all the layers in AE composition and choose Layer -> Pre-compose... (Ctrl/Cmd+Shift+C) Done! Switch back to your Master comp and apply your desired effect(s) 
    You may loose some effects or/and transitions while travelling from PrPro to AE via Adobe Dynamic Link, whereas you don't while travelling back
    (If you start building your AE composition from scratch right in AE and then need to import it into PrPro, DO NOT export one as PrPro project out of AE, but rather choose Adobe Dynamic Link -> Import After Effects Composition... within PrPro)
    P.S. And yes, submit a feature-request so that Adobe will convert 'Transparent Video' into fully functional 'Adjustment Layer'.

  • How can I use FK description in a BC4J data query component?

    Hi all,
    I am facing the following problem.
    Although I use renderers in the DataEdit component for displaying the descriptions of the FKs this is not useful for the BC4J data query components.
    How can I get the same functionality as in the dataEdit components?
    Thanks in advance,
    Aggelos

    Anfortunately,
    This is not the same when I have a DataQuery component.
    The question now becomes as following:
    How can I use FK description in a BC4J data query component?
    Thanks in advance
    Aggelos

  • How can I use TrueSequenceFactory with multiple sequences

    In the post "How to use existing Oracle sequences using KODO" answered
    by Marc Prud'hommeaux a "sample code" was given. But seems to me that
    example will only work with a single Oracle sequence for the entire
    system. Is this right?
    How can I use TrueSequenceFactory with primary-keys and their
    respective existing sequences? Can you (SolarMetric guys) provide me a
    sample code?

    The problem is that you are using application-identity. When you
    specify an objectid-class, we treat is automatically as application
    identity. To resolve this, I would recommend removing both the
    objectid-class and identity-type atributes from your class. With
    "objectid-class" in place, we asssume that you wil take care of identity.
    Eduardo Bobsin Machado wrote:
    I'm using Kodo 2.4.0, Oracle 9i, JBoss 3.0.4, the Kodo jars are in the
    JBoss' lib/ext.
    Well, I'll show what I have...
    This is the script of my table:
    CREATE TABLE LINEUP_VOYAGE (
    VOYAGEID NUMBER (10) NOT NULL,
    VESSEL_NAME VARCHAR2 (1000) NOT NULL,
    CONSTRAINT PK_LINEUP_VOYAGE
    PRIMARY KEY ( VOYAGEID ) ) ;
    This is an excerpt of my .jdo file:
    <class name="LineupVoyage" objectid-class="LineupVoyageId"
    identity-type="datastore">
    <extension vendor-name="kodo" key="table" value="LINEUP_VOYAGE"/>
    <extension vendor-name="kodo" key="sequence"
    value="LINEUP_VOYAGEID_SEQ"/>
    <extension vendor-name="kodo" key="pk-column" value="VOYAGEID"/>
    <extension vendor-name="kodo" key="lock-column" value="none"/>
    <extension vendor-name="kodo" key="class-column" value="none"/>
    <field name="vesselName">
    <extension vendor-name="kodo" key="data-column"
    value="VESSEL_NAME"/>
    </field>
    <!--field name="id" primary-key="true">
    <extension vendor-name="kodo" key="data-column"
    value="VOYAGEID"/>
    </field-->
    </class>
    As you can see, the "id" field is commented.
    And this is my class:
    package br.com.fertimport.entity;
    import java.util.*;
    public class LineupVoyage {
         private String vesselName;
    //     private long id;
    //     public LineupVoyage(long id) { this.id = id; }
    //     public long getId() { return id; }
    //     public void setId(long id) { this.id = id; }
         public String getVesselName() { return vesselName; }
         public void setVesselName (String vesselName) { this.vesselName =
    vesselName; }
    The "id" attribute is commented.
    Now the questions...
    To use ClassSequenceFactory must the identity-type of my entities be
    application or datastore?
    Is the "objectid-class" parameter required in this case?
    As you see, all references to the "id" property are commented. Can I
    use this property to represent my object id?
    If not, how can I identify my object with something like a long?
    The last question is related to my architecture: one VM with the EJBs
    (entity and session) and another VM with the web classes and JSPs,
    connected by a session facade. I don't want to use any Kodo or JDO stuff
    in the web tier. Is this possible?
    Stephen Kim
    [email protected]
    SolarMetric, Inc.
    http://www.solarmetric.com

  • How can I use photos in FCEHD?

    How can I use photos in FCEHD? (I'm new to the thing - done just one video project so far).
    When I imported photos from Aperture (first into the folder on desktop, and then from desktop to the Browser in FCEHD3.5, the photos have a black bar/a gray space above and below, and they appear too wide a bit on the right side, as if coming out of the Canvas'frame.
    Is it a way to fit them into the 4:3 format, so they fit the whole screen (BTW - what view I should have set for Viewer and Canvas? A 100% or "Fit The Screen" view?).
    Also: Is there a way to enter the same Transition in between all of my photos in the Timeline? (if so - how?)

    Re the Canvas window ... before exporting your sequence, rendering, etc it should be set to Fit to Window, this can avoid problems
    In FCE you can't set your own default transition. It is always the Cross Dissolve. If that is the one you want to use, when you drop your pics onto the timeline you can drag them over to Overwrite with Transition or hit Shift-F10. If you want to use multiple occurances of another trans, apply it once, double click to put it in the Viewer then just drop that down onto your clips
    I haven't used Aperture but I think that how they appear in the timeline depends upon the size they are created in. Search this forum, there is plenty of info about that. Generally Final Cut sizes the pics to fit into your video sequence. Put a pic in the timeline, click it, select Edit>Remove Attributes and from the submenu select Motion, see what happens

  • How can i use my custom login page in a custom partner application ?

    Dear All,
    I'm trying to customize a login page displayed other than the default sso login page
    by submiting my form to the regular pl/sql procedure : "PORTAL.wwptl_login.login_url"
    but i tried to type the requested partner application url in the browser i got the sso
    login page other than my custom login page. So, How can i use my custom login page in a custom partner application ?
    Regards,
    Mohammed Amin
    [email protected]

    I cannot begin to express my level of frustration. I have been trying to use the composition widget light box display for some time now. I drag the widget to my document. The default widget has three small trigger boxes and a large area made up of a forward and backward button, a background, a text box and a frame for your image.
    My steps have been …
    I click on the little trigger box.
    I click on the frame that holds the main image.
    I go to the fill menu and browse my computer for my image and then click OK.
    IT shows up on my screen. Yay
    I attempt to continue using the next two trigger boxes provided in the widget.
    After that, I add more by clicking on the little plus sign.
    This is where all heck breaks loose.
    Every single time I attempt to add thumbnails, something messes up. When I go to preview, either not all of my main images show up, or it starts with the wrong one, or some are missing. I have looked and looked for help on this and the only thing I can find is how easy it is to create a great portfolio lightbox display.  But as we know, that only works when your thumbnails are the same image as the images in your lightbox. If you want something different, you have to use the composition wizard. I am finding it extremely difficult and confusing to customize.
    Is there an exact sequence you need to use to add images to the slideshow? I am my wits end.

  • How can I use LabVIEW to send the equivalent of a CTRL D (in VT 100 format) out the serial port of my computer?

    I am trying to write a vi that interfaces with a piece of OEM equipment that is set up to talk with a VT 100 terminal. I can't seem to locate the ASCII equivalent string (if there is such a thing) of a CTRL D. Is there a vi that emulates VT 100 commands?

    If I recall, CTRL-D is EOF on most ASCII tables.
    You'd probably have to use an escape sequence
    or if you can use an unsigned 8-bit that might be
    easier.
    In article <[email protected]>, TLS
    wrote:
    > How can I use LabVIEW to send the equivalent of a CTRL D (in VT 100
    > format) out the serial port of my computer?
    >
    > I am trying to write a vi that interfaces with a piece of OEM
    > equipment that is set up to talk with a VT 100 terminal. I can't seem
    > to locate the ASCII equivalent string (if there is such a thing) of a
    > CTRL D. Is there a vi that emulates VT 100 commands?

  • How can i use passbook in romania?

    How can i use passbook in romania?
    when i open the app and i touch app store, something is loading and aftept waiting 10 minutes is still loading...
    how can i use it?
    please help me
    iPhone 4s I.O.S 6

    Re the Canvas window ... before exporting your sequence, rendering, etc it should be set to Fit to Window, this can avoid problems
    In FCE you can't set your own default transition. It is always the Cross Dissolve. If that is the one you want to use, when you drop your pics onto the timeline you can drag them over to Overwrite with Transition or hit Shift-F10. If you want to use multiple occurances of another trans, apply it once, double click to put it in the Viewer then just drop that down onto your clips
    I haven't used Aperture but I think that how they appear in the timeline depends upon the size they are created in. Search this forum, there is plenty of info about that. Generally Final Cut sizes the pics to fit into your video sequence. Put a pic in the timeline, click it, select Edit>Remove Attributes and from the submenu select Motion, see what happens

  • How can I use 2 Apple IDs in Itunes? I have 2 IOS Devices. They each have there own AppleID. What is the proper way to sync both of them to Itunes?

    How can I use 2 Apple IDs in Itunes? I have 2 IOS Devices. They each have there own AppleID. What is the proper way to sync both of them to Itunes? I wanted my teenager's AppleID to be different from mine so that she couldn't charge stuff to my AppleID, therefore I created me another one. Now when I go to Sync either device, it tells me that this IOS device can only be synced with one AppleID. Then I get a message to erase it, not going to do that, lol. If I logout as one ID and login as the other, will it still retain all synced information on the PC from the first IOS device? If I can just log in out of the AppleID, then I have no problem doing that as long as the synced apps, music, etc stays there for both. I am not trying to copy from one to the other, just want to make sure I have a backup for the UhOh times. If logging in and out on the same PC of multiple AppleIDs is acceptible then I need to be able to authorize the PC for both devices. Thanks for the help. I am new to the iOS world.

    "Method Three
    Create a separate iTunes library for each device. Note:It is important that you make a new iTunes Library file. Do not justmake a copy of your existing iTunes Library file. If iTunes is open,quit it.
    This one may work. I searched and searched on the website for something like this, I guess I just didn't search correctly, lol. I will give this a try later. My daughter is not be back for a few weekends, therefore I will have to try the Method 3 when she comes back for the weekend again. "
    I forgot to mention that she has a PC at her house that she also syncs to. Would this cause a problem. I am already getting that pop up saying that the iPod is synced to another library (even though she is signed in with her Apple ID to iTunes) and gives the pop up to Cancel, Erase & Sync, or Transfer Purchases. My question arose because she clicked on "Erase & Sync" by mistake when she plugged the iPod to her PC the first time. When the iPod was purchased and setup, it was synced to my PC first. When she went home, she hooked it up to her PC and then she erased it by accident. I was able to restore all the missing stuff yesterday using my PC. However, even after doing that it still told me the next time I hooked it up last night that the iPod was currently synced with a different library. Hopefully, you can help me understand all this. She wants to sync her iPod and also backup her iPod at both places. Both PCs have been authorised. Thanks

  • How can i use my account without the billing info, as i do not have a credit card. and my shipping and billing info is under US. i'm in singapore. how do i change this?

    how can i use my account without the billing info, as i do not have a credit card. and my shipping and billing info is under US. i'm in singapore. how do i change this?

    If you are just visiting Singapore, then leave the account as it is. If you have moved there, then view your account using the iTunes app on a Mac or PC and change the country/region to your current location and address. If you do not have a bank card, you can fund your account using iTunes gift cards if available in Singapore.

  • How can I use one photo twice in a slideshow

    I am in iPhoto '11 9.4.3 making a slideshow to send to iDVD for my mother-in-laws funeral next Wednesday.
    How can I use this one particular photo of her several times in the slide show.
    I have tried copy/past and that does not seem to work.
    Thanx in advance

    I would just duplicate the picture several times and keep inserting duplicates ...

  • How can i use microsoft word on ipad 2

    how can i use the microsoft application on my ipad 2?

    The Pages app is also compatible with MS Word. Unlike some of the others mentioned, the document is actually stored on the iPad as opposed to 'the clouds'. Again, most of those mentioned are cut down versions of MS Word.
    Stand back and look at this constructively; do you need to regularly access to the document from more than one computer/device without the need to keep amending your document on your computer and sending it to your iPad? If so, Documente to Go etc may be the best choice.

  • How can I use the credit on my account instead of credit card to buy apps?

    I have a gift card credit on my account but when I want to buy an app it takes me to my credit card details. How can I use my credit on my account instead of credit card?

    You shouldn't have to put in a credit card, no, but from time to time the iTunes Store seems for some reason to try to insist on one. If just confirming your mailing address doesn't stop it from complaining, go here:
    http://www.apple.com/support/itunes/contact/
    and follow the instructions to report the issue to the iTunes Store.
    Regards.

  • How can i use one SQL statement to solve problem?

    How can i use one SQL statement to solve the question below?
    For a Table named A, there is a column named F(char type).
    Now select all the records where F like '%00' and update their F value to '%01'
    Just one SQL statement.Do not use PL/SQL block.
    How to do that?
    Thanks.

    What is the data volume for this table?
    Do you expect lots of rows to have '%00' as their value?
    Following two statements come to mind. Other experts would be able to provide better alternatives:
    If you have index on SUBSTR(f, 2):
    UPDATE A
    SET    f = SUBSTR(f,
                      1,
                      length(f) - 2) || '01'
    WHERE  substr(f,
                  -2) = '00';If most of the rows have pattern '%00':
    UPDATE A
    SET    f = SUBSTR(f,
                      1,
                      length(f) - 2) ||
               DECODE(SUBSTR(f,
                             -2),
                      '00',
                      '01',
                      SUBSTR(f,
                             -2));

Maybe you are looking for

  • Can't connect via Built-in ethernet

    Can connect to internet via AirPort, but not by Built-in Ethernet. Network status says "The cable for the Built-in Ethernet is not plugged in". BUT it is and it is live because I have plugged it into another computer and it works fine. How do I check

  • How can I move ALL Tools to the left side of the Acrobat XI interface?

    Hi, all: I really tried to find this in assorted Adobe 'resources'. I looked in 'Workspace'. I'm burnin' work time here. ALL Tools, Fill & Sign, Comments, the whole schmear. HELP! I really didn't want to be fenced in to just the "Acrobat Feature Requ

  • IPod Nano 6th gen not syncing despite reset

    My Dad's iPod Nano 6th generation is not syncing with iTunes. He used it first with iTunes on a MacMini G4 and – with later versions of iTunes – ran into trouble while syncing. Now he owns a Mac Mini mid 2010 with a brand new installation of Maverick

  • When clicking "Open" in InDesign, can I have it open up to Bridge instead of Finder?

    I'm looking to quit using Finder because it doesn't work well with our server (PC based). I would like when in InDesign or Photoshop, and I click to open a new file it would open up to Bridge instead of Finder (or Explorer in the PC world). Is this p

  • In desperate need of some wisdom!

    Hello, I wonder if anyone can help me, it seems everywhere i search for a solution to this problem, im faced with brick walls! A friend gave me his PowerMac G4 many years ago, its running OSX 10.3, but i recently bought snow leopard to upgrade it. Th