Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Pillar

843854Jun 20 2003 — edited Jun 20 2003
Hello.
I am importing data from pillar file to Oracle.But experienced a problem when tha data type ie varchar in pillar is of bigger size.
By pillar data type is varchar(65500) I changed this size to varchar(4000) programtically (ie when I create the tables in Oracle data base programatically),as it complined abt the size.But during the data import the data are not imported for the particulat column Note:only this column.Its give me null value.Later I founfd that its not reading data from the particular column from the pillar file.
Does anyone has an annswer pls let me know.Or if u find some alternate solution to import data from pillar to oracle you are welcomed
Thnaks in advance

Shaiju

Comments

843806
I figured it out myself. I believe it is a bug in the implementation of ToolTipManager, which doesn't handle the mouseExited correctly. I basically change its implementation using the following code. Since you cannot subclass ToolTipManager, I copied over the code of original ToolTipManager and modified the mouseExited function. Then, let widget use my new ToolTipManager by overrid setToolTipText() function.
	public void mouseExited(MouseEvent event) {
		boolean shouldHide = true;
		
		if (insideComponent == null) 
		{
			// Drag exit
		} 

		if (window != null && event.getSource() == window) 
		{
			// if we get an exit and have a heavy window
			// we need to check if it if overlapping the inside component
			Container insideComponentWindow = insideComponent.getTopLevelAncestor();
			Point location = event.getPoint();
			SwingUtilities.convertPointToScreen(location, window);

			location.x -= insideComponentWindow.getX();
			location.y -= insideComponentWindow.getY();
            
			location = SwingUtilities.convertPoint(null,location,insideComponent);
			
			if (location.x >= 0 && location.x < insideComponent.getWidth() &&
				location.y >= 0 && location.y < insideComponent.getHeight()) 
			{
				shouldHide = false;
			} 
			else 
			{
				shouldHide = true;
			}
		} 
		else if(event.getSource() == insideComponent && tipWindow != null) {
			Window win = SwingUtilities.getWindowAncestor(insideComponent);
			
			if (win != null) 
			{	// insideComponent may have been hidden (e.g. in a menu)
				Point location = event.getPoint();
				SwingUtilities.convertPointToScreen(location, insideComponent);

				Rectangle bounds = insideComponent.getTopLevelAncestor().getBounds();
				Point loc = new Point(0, 0);
				SwingUtilities.convertPointToScreen(loc, tip);
				bounds.x = loc.x;
				bounds.y = loc.y;
				bounds.width  = tip.getWidth();
				bounds.height = tip.getHeight();
				
				if (location.x >= bounds.x && location.x < (bounds.x + bounds.width) &&
					location.y >= bounds.y && location.y < (bounds.y + bounds.height)) 
				{
					shouldHide = false;
				} 
				else 
				{
					shouldHide = true;
				}
			}
		}
        
		if (shouldHide) 
		{        
			enterTimer.stop();
			
			if (insideComponent != null) 
			{
				insideComponent.removeMouseMotionListener(this);
			}
			
			insideComponent = null;
			toolTipText = null;
			mouseEvent = null;
			hideTipWindow();
			exitTimer.restart();
		}
	}
843806
I have the same problem, but I don't understand your code, you have some vars with no definition.. as far as I saw when it's an applet (or JApplet) when you got over the ToolTip the MouseExited event is activated...
Can you explain it a little bit please?
Thanks
843806
Ok, let me see if I have understood, you took the code of ToolTipManager (where did you get it?) create your own class and modified one method by what you have there.. which I suppose should work.. and then you use it on your own component...I guess with sharedInstance.. where did you place this?
843806
I submitted a bug report to Sun on July 1, 2007 and you can monitor this bug on the Java Bug Database at:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6577663

You can download Java's source code from Java SE download web site. My code was basically modified from the original ToolTipManager. The ToolTipManager is implemented as a singleton with only one instance available and it is created automatically. Its instance can be obtained through ToolTipManager.sharedInstance. Since I have my modified version of ToolTipManager, I have to let my swing component to use my manager instead of default. Then, I need to override the setToolTipText() method for JComponent to register my manager. Here is the code:
// Override the function to use our customized tooltip manager instead.
 public void setToolTipText(String text) {
    MyTooltipManager mytoolTipManager = MyToolTipManager.sharedInstance();
    String oldText = getToolTipText();
    putClientProperty(TOOL_TIP_TEXT_KEY, text);

   if (text != null) {
      if (oldText == null) {
        mytoolTipManager.registerComponent(this);
     }
   } 
   else {		
      mytoolTipManager.unregisterComponent(this);
   }
 }   
You will see setToolTipText() has done much more than just setting the tooltip text value. You can get better understanding on how it works by studying on the source code of JComponent.
843806
I'm sorry to disturb you again, I try to download the source code, but it asks me many libraries to create the code (basically having problems with flex and motif...), i'm a little bit frustrated already.. could you be so kind to send me the code of ToolTipManager?, my email is miguelangelhdz@hotmail.com
Thanks
843806
I tried the workaround on my system, but it won't run. I get

Exception in thread "AWT-EventQueue-1" java.lang.IllegalAccessError: tried to access method javax.swing.JComponent.getInputMap(IZ)Ljavax/swing/InputMap; from class javax.swing.MyTooltipManager
at javax.swing.MyTooltipManager.shouldRegisterBindings(MyTooltipManager.java:404)
at javax.swing.MyTooltipManager.registerComponent(MyTooltipManager.java:350)

Obviously, the class makes calls to non-public Swing functions, which are blocked. How did you solve this problem?
1 - 6
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Jul 18 2003
Added on Jun 20 2003
1 comment
99 views