Bug in binding a Jtable to a Temporary Vo

I've a JClient app in vich I create a Temporary VO wich is not based upon a table.
I try to bind it to a JTable I get an error :
(oracle.jbo.DMLException) JBO-26044: Error while getting estimated row count for view object ProvaVo, statement SELECT count(1) FROM () ESTCOUNT.
When I bind the same Vo to a form it works.
If I remember right this was a bug already fixed (I'm using 9.0.4 production on Windows).
Does anyone know how to avoid this ?
Tks
Tullio

Yes using the WorkAround You suggested I don't have the JBO Error anymore.
I didn't reproduce with the tester because the tester doesn't use JTable for a single Vo (or, at least, I didn't find the way).
I suspect the problem is in the JTable binding because I debbugged Your code and I found a place in wich a test isVisible (applied to a rowset or to a VO, I don't remember) fails and then it "return 0".
The flag tested by that method was setted, in my analysis, only by the execute() wich is not called for a temporary vo. (this is correct because otherwise the Vo would result empty).
Tks
Tullio

Similar Messages

  • How to bind a JTable in runtime.

    Hello Guys,
    Anyone know tell me how to bind a JTable adf Swing at Runtime?
    In other words, I want to create the bindings when the application to be running.
    Thanks in advanced.

    Try the static createAttributeListBinding() methods in JUTableBinding.
    Sascha

  • [svn:fx-trunk] 5409: Fix to bug when binding to constraints.

    Revision: 5409
    Author: [email protected]
    Date: 2009-03-18 21:48:06 -0700 (Wed, 18 Mar 2009)
    Log Message:
    Fix to bug when binding to constraints. Setting real width/height values on ConstraintRow/Column should always register that object as being not content-sized.
    QE Notes: None
    Doc Notes: None
    Bugs: SDK-19041
    Reviewer: Deepa
    Testing: checkintests, Mustella containers
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-19041
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/utilityClasses/ConstraintC olumn.as
    flex/sdk/trunk/frameworks/projects/framework/src/mx/containers/utilityClasses/ConstraintR ow.as

    error dateField not selecion date 27/11/2002 ?
    This is bug flex 3 ?
    thanks

  • BC4J bug with "bind variables" JBO-27122 ORA-01008

    I think we are found a BUG using BC4J with bind variables in a view object.
    If the bind variable appear in the WHERE condition two or more times at
    the beginning of the query the above error occur.
    oracle.jbo.SQLStmtException: JBO-27122: SQL error during statement preparation. Statement:
    SELECT Emp.EMPNO,Emp.ENAME,Emp.JOB,Emp.MGR,Emp.HIREDATE,Emp.SAL,Emp.COMM, Emp.DEPTNO
    FROM SCOTT.EMP Emp
    WHERE :1 <=10000 and :1 <= sal and :2=20
    java.sql.SQLException: ORA-01008: not all variables bound
    Otherwise if bind variable apper two or more times, but not together
    like this sample:
    WHERE :1 <=10000 and :2=20 and :1 <= sal
    the error not occur.
    We prove this with:
    JDeveloper 9.0.5.2 (build 1618)Business Components Version 9.0.5.16.0
    JDeveloper 9.0.5.0 (build 1375)Business Components Version 9.0.5.13.52
    I looking for a patch! or acceptable workaround.
    Tx for your help!
    diego.
    /* the cliente app */
    ApplicationModule am = Configuration.createRootApplicationModule("business_tier.AppModule","AppModuleLocal");
    ViewObject vo = am.findViewObject("EmpView");
    vo.setWhereClauseParam(0,"100");
    vo.setWhereClauseParam(1,"20");
    Row emp = vo.first();

    This is a known bug (1326006). The workaround is to use:
    vo.setWhereClauseParam(0,"100");
    vo.setWhereClauseParam(1,"20");
    vo.setWhereClauseParam(2,"20");
    Hope this helps,
    Lynn
    Java Tools Team

  • Possible Bug When Binding Data to ContentPresenter ToolTip Attribute

    Hello everyone,
    I'm developing a small application using WPF. I have a custom ListBox control which contains a number of CheckBox entries paired up with a ContentPresenter object which displays some text obtained from a custom generic object.
    If I bind the ContentPresenter 'Content' node to one of the properties of my class, it will display the text I want correctly. However, I cannot do the same with its 'ToolTip' attribute.
    Here's an excerpt of my XAML.
    <Window.Resources>
    <local:SandboxProfiles x:Key="profiles"/>
    <DataTemplate x:Key="ListBoxItemTemplate">
    <!-- The ToolTip attribute doesn't accept dynamic data bindings (maybe a bug?) within the ContentPresenter node.
    Therefore, the attribute has to be inserted in the parent node (WrapPanel) for it to work. -->
    <WrapPanel ToolTip="{Binding Element.FriendlyDescription}">
    <CheckBox IsChecked="{Binding IsSelected}" VerticalAlignment="Center" />
    <ContentPresenter Content="{Binding Element.TypeString, Mode=OneTime}" Margin="2,0" />
    </WrapPanel>
    </DataTemplate>
    </Window.Resources>
    This line works absolutely fine like this,
    <ContentPresenter Content="{Binding Element.TypeString, Mode=OneTime}" Margin="2,0" />
    However, this doesn't work
    <ContentPresenter Content="{Binding Element.TypeString, Mode=OneTime}" ToolTip={Binding Element.TypeString} Margin="2,0" />
    Note I'm using the exact same pattern here, only that I'm applying it to the ToolTip attribute instead of Content. This doesn't work. It compiles, no exceptions, but no tooltip is displayed.
    However, if I bind the ToolTip attribute of the CheckBox node or the parent WrapPanel node in the exact same way, it
    does work. This works,
    <WrapPanel ToolTip="{Binding Element.TypeString}">
    And this works too,
    <CheckBox IsChecked="{Binding IsSelected}" ToolTip="{Binding Element.TypeString}" VerticalAlignment="Center" />
    I've searched the documentation and nowhere does it say I should expect ContentPresenter's 'ToolTip' attribute to behave differently than with any other XAML component.
    This has led me to believe this is a bug in the WPF runtime. If, on the other hand, I'm missing something here, please, do let me know.
    Thank you.

    Your problem is because you're putting  a tooltip on a contentpresenter - which isn't going to respond to mouse over unless you get your mouse over it just so.
    You can easily reproduce that if you throw a little markup in a new mainwindow:
    <Grid Name="myGrid">
    <ContentPresenter ToolTip="Banana"/>
    </Grid>
    Substitute TextBlock for contentpresenter
    <TextBlock Text="Whatever" ToolTip="Banana"/>
    And it works easily.
    <TextBlock Text="{Binding Element.TypeString, Mode=OneTime}" Margin="2,0" />
    Maybe I'm missing something but I can't really see why you have a contentpresenter at all.
    Assuming typestring is a string as it's name rather implies.
    Hope that helps.
    Recent Technet articles:
    Property List Editing ;  
    Dynamic XAML
    Substituting the ContentPresenter node for a simple TextBlock as you said worked for me, thank you.
    But Magnus is right in that you do have mouse-over events with ContentPresenter components; only that for some reason I don't know, they only work when the ToolTip attribute is set to a hardcoded string and no bindings are happening. So it does respond to
    the mouse but it doesn't display anything that has been dynamically bound to it, for some reason.

  • Bug with binding / statement cache?

    And the next trouble... :(
    When Sql on two different OracleCommand's is equals, but parameter types differs, exceptions raised.
    Two different exception raised, depends of AddToStatementCache property, on call ExecuteReader or on call Read().
    Test case:
                OracleConnectionStringBuilder csb = new OracleConnectionStringBuilder();
                csb.UserID = "xxxxxx";
                csb.Password = "xxxxxxx";
                csb.DataSource = "xxxxxxxx";
                OracleConnection conn = new OracleConnection(csb.ToString());
                conn.Open();
                string sql = @"SELECT :v1 FROM DUAL";
                // Create first command
                OracleCommand cmd = conn.CreateCommand();
                cmd.BindByName = true;
                cmd.CommandText = sql;
                // Bind number parameter
                OracleParameter p1 = cmd.CreateParameter();
                p1.ParameterName = "v1";
                p1.Value = 1000.123m;
                cmd.Parameters.Add(p1);
                // Select number value
                OracleDataReader reader1 = cmd.ExecuteReader();
                reader1.Read();
                decimal d1 = reader1.GetDecimal(0);
                // dispose first reader and command
                reader1.Dispose();
                cmd.Dispose();
                // Create second command with equals Sql
                OracleCommand cmd2 = conn.CreateCommand();
                cmd2.BindByName = true;
                cmd2.CommandText = sql;
                // if uncomment next line, exception (1) changes to exception (2)
                cmd2.AddToStatementCache = false;
                // Bind string parameter
                OracleParameter p2 = cmd2.CreateParameter();
                p2.ParameterName = "v1";
                p2.Value = "sdf g sdfg sdfg sdfgsdf";
                cmd2.Parameters.Add(p2);
                // Select scalar string
                OracleDataReader reader2 = cmd2.ExecuteReader(); // Exception (1)! ORA-01475: must reparse cursor to change bind variable datatype
                reader2.Read();  // Exception (2)! ORA-01722: Invalid number
                string s2 = reader2.GetString(0); Well, few questions:
    * How i can force "reparse" cursor, if need???
    * Why statement cache dont use parameter signatures to distinguish statements with equals SQL and different parameter types??
    * Where i can post that bug (and some other) to quick answer from ODP.NET support? In this forum only? Anywhere else?
    Thanks.

    Hi,
    I tried your code, but get the 1722 every time, and dont seem to be able to get the 1475.
    I think the explanation here is that ODP uses the command text only in determining whether to pull the statement from the cache (ie, not the data types, as you've seen).
    With respect to your questions:
    1) I'd have thought con.PurgeStatementCache() would have done it, but that didnt work for me. I’ve tried Statement Cache Purge=true in the connect string, cmd.AddStatementToCache=false, and con.PurgeStatementCache(), but none of them make the code work. I'm guessing the statement is getting added to the cache every time even though we're doing our best not to, and that’s why the problem behavior. I'm looking into that further.
    2) I'd assume that development just didnt take this scenario into account. Typically the data type of a bind variable in any given statement wouldnt change.
    3) If you have an Oracle Support contract, just log a SR via Metalink (http://metalink.oracle.com)
    Cheers,
    Greg

  • Bug with binding unnamed parameters

    Bug report (I must post it in another place?).
    If OracleCommand.BindByName == true and any of binded parameters has empty name, ExecuteReader raises the exception:
    Exception AccessViolationException:
    Attempted to read or write protected memory. This is often an indication that other memory is corrupt
    I think, this exception must be more intelligible :)

    Hi,
    Theres a bug aleady filed on this (5447495), but it hasnt been addressed yet.
    Cheers,
    Greg

  • Bug: DatagramChannel bind/connect local address

    What are the chances of getting bug 6431343 fixed in JRockit?
    Basically, I need to be able to send a message from a specific local UDP port, and I also need to know the local address that the message will originate from.
    So when I bind using
    channel.socket().bind(new InetSocketAddress(9999));
    and then connect to the remote address
    channel.connect(new InetSocketAddress("localhost", 0));
    Then DatagramChannel should report the local address that any messages will originate from when I call
    channel2.socket().getLocalSocketAddress();
    but it instead seems to return a cached copy of the wildcard address as the local address.
    However, the behavior IS correct in a plain DatagramSocket.
    Here's a link to the bug:
    http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6431343
    Thanks very much for your attention.

    As you have assumed, we use Sun's networking code and therefore inherit their bugs. All bugs that Sun fix are fixed in the JRockit version with the same JDK level (i.e. Sun 5.0u8 -> JR 5.0u8).
    However, if you have a support contract with BEA (for JRockit, WebLogic etc) then you can open a ticket with BEA Support. The issue will be investigated, and if it is critical and no good workaround can be found then you will be provided with a patch.
    -- Henrik

  • Beans Binding with JTable Problem

    Does anyone have an idea on how to make the columns of a JTable (with binded elements) not editable? I'm currently using the binding feature of NetBeans 6.0 M9.

    Override the tables isCellEditable method to always return false.

  • Can anybody turn off "F2" key bind in JTable

    Hi all,
    I have following problem,
    I use global key action for key "F2", I also use as JTable cell editor my own editable combobox (extended from JComboBox). I have to turn off "F2" key action, which starts and stops editing cells in JTable, but I dont know how,
    can anybody help me?
    Mathew, HSIGP

    i have found solution: :)
              //deleting of f2
              KeyStroke f2=KeyStroke.getKeyStroke("F2");
              int type=WHEN_ANCESTOR_OF_FOCUSED_COMPONENT;
              InputMap imap=getInputMap(type);
              InputMap m=new InputMap();                    
              for (int i=0;i<imap.allKeys().length;i++)
              if (imap.allKeys()!=f2) m.put(imap.allKeys()[i],imap.get(imap.allKeys()[i]));          
              setInputMap(type,m);
              //end of deleting f2
    not best but working :),
    Mathew

  • EA3/EA2/EA1 - Bind Variables in PL/SQL

    EA1 seems to have taken a backward step when it comes to supporting bind variables in PL/SQL.
    Back in 1.1.3, according to the bugs fixed list, we apparently fixed bug 5884935 (BINDS IN A PL/SQL STATEMENT HAS "NOT ALL VARIABLES BOUND" ERROR), although this was only ever when running as scripts (as per Bind variables in PLSQL bug not fixed?
    Now according to the 1.2 documentation, bind variables are not supported in the script runner (section 1.7.2) and the SQL*Plus variable command is not supported (section 1.7.1). However, I can run the following code "successfully" (no errors reported but the substitution text entered does not appear in the dbms_output):
    variable bind_text varchar2(30);
    declare
    l_text varchar2(30);
    begin
    :bind_text := '&sub_text';
    dbms_output.put_line('Bind text: "' || :bind_text || '"');
    end;
    Now in EA1, running this as a script results in "ORA-01006: bind variable does not exist"
    Running the variable statement results in "ORA-00900: Invalid SQL Statement" and running the PL/SQL results in "ORA-1008: not all variables bound".
    Can someone from the SQL Developer team please comment on the intended support for bind variables in PL/SQL?
    Thanks,
    theFurryOne

    I know that the variable command isn't supported (as I said above), but that was also the case in 1.2, where it did actually sort of work.
    I am not talking about local PL/SQL variables declared within the PL/SQL - I am trying to get user entered values into the PL/SQL in the same way as prompting for bind variable values in SQL.
    So using SQL Developer bind variables inside PL/SQL is my end goal - preferably when running anonymous PL/SQL blocks as statements in the worksheet.
    However, as there have been "fixed" bugs to enable bind variables in PL/SQL, which require the use of SQL Plus commands that are not supported in SQL Developer (ie variable), I am trying to work out what the development team think the intended support for bind variables in PL/SQL is. Then I will know if what I want needs to be reported as a bug or logged as an enhancement request.
    theFurryOne

  • Feature/Bug Fix list for 10.2.0.4

    I know 10.2.0.4 is expected in July. I'm currently running 10.2.0.3 and interested in it because it has a fix for Bug 5082178 - "Bind peeking may occur when it should not." I'm interested in knowing what other improvements it contains.
    Can anyone point me to a list of features and bugs planned for the 10.2.0.4 release?
    Thanks,

    The README/ Metalink note for the patchset should include the list of all the bugs that are fixed. I don't believe Oracle publishes the set of bug fixes that will actually be part of the patchset until much closer to the release date since bugs fixes get added and removed during the final testing process.
    Justin

  • 2.1 EA1 Bug No promt for substitution variables

    Didn't see a post for this yet. In this release, I am not being prompted for replacement variables when I use & in my query.
    SELECT &1 from dual;
    ORA-01008: not all variables bound
    01008. 00000 -  "not all variables bound"
    *Cause:   
    *Action:
    SELECT &&1 from dual;
    ORA-01745: invalid host/bind variable name
    01745. 00000 -  "invalid host/bind variable name"
    *Cause:   
    *Action:

    Substitution variables have to be defined:
    define 1 = 'Defined'
    select '&1' from dual;A current 2.1 EA1 bug will let you only execute this as script (F5).
    Bind variables have to be given through the dialog:
    select ':1' from dual;A current 2.1 EA1 bug will let you only run this as statement (F9).
    To the development team:
    Please log the bug that bind variables can't be used when executing as script.
    Regards,
    K.

  • How to set JTable cell editable/non-editable dynamically using NetBean?

    I am using NetBean 6.5, create a database desktop application, I using the persistence entity manager to bind my JTable with database.
    Now, I want to set practicular cells which are enable and disable, I tried to create my own table model and override the isEditable() method, which it seems didn't work. I guessed the problem is the persistence connection between my Table and database.
    How can I solve it? Any example? I just googled the web and can't find example which use netbean combined with database. I know that a single JTable would work when creating your own model.
    thx.

    I know what coding i did, Yes u r right but im new to GUI programming only,
    That's why i posted it to forums, I gone through the Control Flow Statements link what u have given.
    U didnt get my question at all.
    Again the problem im facing is the table is already displayed with 2nd column uneditable.
    When some Action done on table, i need to make 2nd column editable at run time.
    Thanks if u provide me the solution instead of deciding what type of programmer im.

  • Customized JTable can't find keyPressed() event

    I'm writing a new table component that extends from JTable. One of the behaviors to be implemented is to prevent the up and down arrow keys from navigating to an adjacent cell. Problem is, when a cell is selected (and being edited), something is handling the keyPressed(KeyEvent e) method before the table. I tried adding a KeyListener() to the component, but that doesn't help. It never gets there either. I suspect it's down inside the editor component - perhaps at the document level? The table does get the keyReleased(KeyEvent e) method okay.
    The selected cell does change, but it does not start editing. Subsequent key events (including keyPressed) are captured at the JTable level and consumed appropriately.
    What I need is to capture the initial keyPressed(KeyEvent e) and consume it...but where is it getting handled?
    Any help? Thanks...

    When the editor is invoked it has the focus and recieves the key events.
    Good Luck with this... I developed my own JTable extension to solve some of the common problems I have with it. It is a mess.
    Beware; there are several bugs still in the JTable. Like you can't operate some JComboBox editors with the keyboard. Also, when in an text editor and focus moves off the JTable the contents are lost.
    I also was interested in changing the default key navigation. I recall that this is not to hard but did not do it.

Maybe you are looking for

  • Link between implementation project configuration (SOLAR02) and ChaRM?

    Dears; We want to benefit from listing all IMG Objects and developments in an implementation project (SOLAR02) to control our transports as we have ChaRM activated on the affected systems. But there seems to be no link/control which has several conse

  • Problem with code-Please Help!!!

    Hey guys i have some problems with the following code: 1. I have to do a stutter and reverse of an array [ 2 4 ] and it should return [ 4 4 2 2 ]. I wrote the code and i get [ 2 2 4 4]. How can this be fixed? public class Part1      public static voi

  • Program Objects Stuck in Running Status

    I have some batch files that runs as  scheduled program objects in Business Objects XI.  They will work correctly for a week or so and then they stay stuck in running status without completing, with several jobserverchild.exe processes running and se

  • Illustrator CC 2014 stops working whenever I click NEW, NEW FROM TEMPLATE or OPEN.

    Illustrator CC 2014 stops working whenever I click NEW, NEW FROM TEMPLATE or OPEN.  I've tried uninstalling and reinstalling; I've also tried disabling graphics card.  Help, please!

  • Wily Instrumentation version incompatibility

    First a few vitals: Solman 7.01(EHp1 SP4) SP 20 for ST400 Enterprise Manager version 8020 Managed system (JAVA): 7.11 Diag Agent (SMD, connected and running succesfully to the Managing system) Introscope Agent 8.1 installed In the SMD Diagnostics Set