Re: Custom Tag

2005-05-13 Thread Abdullah Kauchali

Brandon Goodin wrote:
I see. The question here is whether this is a common database issue
and if it should be supported. However, it does not seem to be a
common issue and there are ways to work around this. My other thought
is why do you have over 250+ IN parameters? 

My guess:  they have a large table with a foreign key.  When they do a 
select for this large
table, they also want to obtain the parent table values specific only to 
*that* resultset.

So we have:
ChildTable
ID COL1COL2FK_ID
--     
001 ABCASD1
002 EDFASE 1
003 EDW746 2
(SELECT * FROM ChildTable)
Now they want to do this:
SELECT * FROM ParentTable where
FK_ID IN ('1', '2')
In two round-trips, you have Master-detail.


Custom Tag

2005-05-12 Thread Ming Xue
Title: RE: Oracle OC4J and signon



Hi 


I am 
very much amazed by Ibatis's ability to generate dynamic sql, which 
isblank in Hibernate. There are a couple predefined tags provided by 
default, But, does the framework support Custom Tags? if so, 
how can I attched them to the FrameWork?

thanks

Ming
[Ming 
Xue]

-Original 
Message-From: Trussell David N 
[mailto:[EMAIL PROTECTED]Sent: Thursday, May 12, 2005 2:35 
PMTo: 'ibatis-user-java@incubator.apache.org'Subject: RE: 
Oracle OC4J and signon

  Bingo! I commented out the security-constraint tag and 
  it all works nicely. 
  I made the assumption that most developers would know what 
  OC4J in the subject meant: Oracle Container for Java. It's based on Orion. My 
  apologies.
  Thank you for all your patience and help, Brice! Now, where 
  did I put that hammer 
  -Original Message- From: Brice 
  Ruth [mailto:[EMAIL PROTECTED]] 
  Sent: Thursday, May 12, 2005 11:59 AM To: ibatis-user-java@incubator.apache.org Subject: Re: Oracle OC4J and signon 
  can you find web.xml? there should be a 
  security-constraint tag in there ... that ties particular pages to a 
  security restriction.
  I wasn't aware that this was running in Oracle's App server as 
  well. If you mentioned that earlier, I apologize. 
  I've never used Oracle's App server ... so my help may be 
  limited in this area. 
  On 5/12/05, Trussell David N [EMAIL PROTECTED] 
  wrote:   
   I can't find a context.xml. As far as I can see, 
  a realm would be  configured in jazn-data.xml and 
  there are no entries in that file.  
   I get one of these entries in my 
  global-applications.log for each time  the pop-up 
  window is presented (meaning when I click "Sign-in" or  "Enter the Store"). I'm not well-versed enough in Java to know 
  what  this means:  
   05/05/12 10:18:04 jpetstore: Servlet error 
   java.lang.SecurityException  at 
  com.evermind[Oracle Application Server Containers for J2EE 10g 
   
  (10.1.2.0.0)].server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:2676) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpApplication.getLocalDispatcher(HttpApplication.java:4734) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpSite.getRequestDispatcher(HttpSite.java:341) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:1368) 
at 
   
  org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1062) 
   
  at  
  org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455) 
   
  at  
  org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279) 
   
  at  
  org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482) 
   
  at  
  org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507) 
   
  at  
  javax.servlet.http.HttpServlet.service(HttpServlet.java:740)  at 
   
  javax.servlet.http.HttpServlet.service(HttpServlet.java:853)  at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:810) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:322) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:270) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112) 
at 
  com.evermind[Oracle Application Server Containers for J2EE  10g  
  (10.1.2.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192) 
at 
  java.lang.Thread.run(Thread.java:534)  
   -Original Message-  From: Brice Ruth [mailto:[EMAIL PROTECTED]]  Sent: Thursday, May 12, 2005 9:30 AM  
  To: ibatis-user-java@incubator.apache.org  
  Subject: Re: Oracle OC4J and signon  

Hmmm ... well, take 
  a look at where the realm is configured. It would  
  have to be in context.xml as well as be referenced in web.xml ... 
On 5/12/05, Trussell David 
  N [EMAIL PROTECTED] wrote:  
   
  Yeah, j2ee/j2ee and ACID/ACID. But it doesn't accept either of those 
two.   
-Original Message-   From: Brice Ruth [mailto:[EMAIL PROTECTED]]   Sent: Thursday, May 12, 2005 9:09 AM   To: ibatis-user-java@incubator.apache.org   Subject: Re: Oracle OC4J and signon   Aha! This is basic realm authentication. I 

Re: Custom Tag

2005-05-12 Thread Larry Meadors
A couple?

Check again.

That is an interesting idea though.

Larry

PS: Please do not reply to other posts with new topics.On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:







Hi 


I am 
very much amazed by Ibatis's ability to generate dynamic sql, which 
isblank in Hibernate. There are a couple predefined tags provided by 
default, But, does the framework support Custom Tags? if so, 
how can I attched them to the FrameWork?
 


Re: Custom Tag

2005-05-12 Thread Brandon Goodin
The functionality does not currently exist. It would be difficult to
implement that functionality in the current iBatis version. It might
be a featuer we'd consider for the next major release of ibatis. What
kind of functionality are you wanting to implement that iBatis does
not deal with?

Also, have you read the dynamic sql whiteboard?
http://opensource.atlassian.com/confluence/oss/display/IBATIS/Improved+Dynamic+SQL+Whiteboard

Brandon

On 5/12/05, Larry Meadors [EMAIL PROTECTED] wrote:
 A couple?
  
  Check again.
  
  That is an interesting idea though.
  
  Larry
  
  PS: Please do not reply to other posts with new topics.
 
 
 On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote: 
  
  Hi 

  I am very much amazed by Ibatis's ability to generate dynamic sql, which
 is blank in Hibernate.  There are a couple predefined tags provided by
 default,  But,  does the framework support  Custom Tags? if so, how can I
 attched them to the FrameWork? 
  
  
 



RE: Custom Tag

2005-05-12 Thread Ming Xue



For 
example, for Oracle in list limitation while using 


select 
* from abc
where 
a in ('a', 'b', 'c', ...)

We 
need to use a Custom tag for this.

Thanks


  -Original Message-From: Larry Meadors 
  [mailto:[EMAIL PROTECTED]Sent: Thursday, May 12, 2005 5:21 
  PMTo: ibatis-user-java@incubator.apache.orgSubject: Re: 
  Custom TagA couple?Check again.That is an 
  interesting idea though.LarryPS: Please do not reply to other 
  posts with new topics.
  On 5/12/05, Ming 
  Xue [EMAIL PROTECTED] 
  wrote: 
  
Hi 

I am very much amazed by 
Ibatis's ability to generate dynamic sql, which isblank in 
Hibernate. There are a couple predefined tags provided by 
default, But, does the framework support Custom Tags? if 
so, how can I attched them to the FrameWork?



Re: Custom Tag

2005-05-12 Thread Brandon Goodin
That is not a clear example. I'm not sure what the problem is that you
are presenting. What tag would you write to accomplish a solution to
the problem you are presenting?

If you are referring to the population of an IN statement then you
could use iterate.

Brandon

On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:
  
 For example,   for Oracle in list limitation while using 
   
 select * from abc 
 where a in ('a', 'b', 'c', ...) 
   
 We need to use a Custom tag for this. 
   
 Thanks 
   
  
 -Original Message-
 From: Larry Meadors [mailto:[EMAIL PROTECTED]
 Sent: Thursday, May 12, 2005 5:21 PM
 To: ibatis-user-java@incubator.apache.org
 Subject: Re: Custom Tag
 
 A couple?
 
 Check again.
 
 That is an interesting idea though.
 
 Larry
 
 PS: Please do not reply to other posts with new topics.
 
  
 On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote: 
  
  Hi 

  I am very much amazed by Ibatis's ability to generate dynamic sql, which
 is blank in Hibernate.  There are a couple predefined tags provided by
 default,  But,  does the framework support  Custom Tags? if so, how can I
 attched them to the FrameWork? 
  
  
 



RE: Custom Tag

2005-05-12 Thread Ming Xue

The Oralce in list limition is 250,  otherwise the sql can not be parsed,
For example:

select * from abc 
where a in ('a', 'b', 'c', ...) 

if there are more than 250 values in the in list, the sql needs to be
rewritten as:

select * from abc
where a in ('a', 'b', 'c'...)
or a in ('x', 'y', 'z'...)
or ...

In this way every inlist is less than 250

The Iterate tag is designed for generating the in-list, for it is not aware
of the Oracle limitation, so is there anyway I can modify the existing
iterate tag or creating a new one?

Thanks



-Original Message-
From: Brandon Goodin [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 12, 2005 5:40 PM
To: ibatis-user-java@incubator.apache.org
Subject: Re: Custom Tag


That is not a clear example. I'm not sure what the problem is that you
are presenting. What tag would you write to accomplish a solution to
the problem you are presenting?

If you are referring to the population of an IN statement then you
could use iterate.

Brandon

On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:
  
 For example,   for Oracle in list limitation while using 
   
 select * from abc 
 where a in ('a', 'b', 'c', ...) 
   
 We need to use a Custom tag for this. 
   
 Thanks 
   
  
 -Original Message-
 From: Larry Meadors [mailto:[EMAIL PROTECTED]
 Sent: Thursday, May 12, 2005 5:21 PM
 To: ibatis-user-java@incubator.apache.org
 Subject: Re: Custom Tag
 
 A couple?
 
 Check again.
 
 That is an interesting idea though.
 
 Larry
 
 PS: Please do not reply to other posts with new topics.
 
  
 On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote: 
  
  Hi 

  I am very much amazed by Ibatis's ability to generate dynamic sql, which
 is blank in Hibernate.  There are a couple predefined tags provided by
 default,  But,  does the framework support  Custom Tags? if so, how can I
 attched them to the FrameWork? 
  
  
 



Re: Custom Tag

2005-05-12 Thread Brandon Goodin
I see. The question here is whether this is a common database issue
and if it should be supported. However, it does not seem to be a
common issue and there are ways to work around this. My other thought
is why do you have over 250+ IN parameters? Maybe you need to
rethink what you are developing. There would seem to be a reson why
there is a 250 cap. Go ahead and drop an enhancement request into
JIRA. We'll consider this in the next major release.

Brandon

On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:
 
 The Oralce in list limition is 250,  otherwise the sql can not be parsed,
 For example:
 
 select * from abc
 where a in ('a', 'b', 'c', ...)
 
 if there are more than 250 values in the in list, the sql needs to be
 rewritten as:
 
 select * from abc
 where a in ('a', 'b', 'c'...)
 or a in ('x', 'y', 'z'...)
 or ...
 
 In this way every inlist is less than 250
 
 The Iterate tag is designed for generating the in-list, for it is not aware
 of the Oracle limitation, so is there anyway I can modify the existing
 iterate tag or creating a new one?
 
 Thanks
 
 
 -Original Message-
 From: Brandon Goodin [mailto:[EMAIL PROTECTED]
 Sent: Thursday, May 12, 2005 5:40 PM
 To: ibatis-user-java@incubator.apache.org
 Subject: Re: Custom Tag
 
 That is not a clear example. I'm not sure what the problem is that you
 are presenting. What tag would you write to accomplish a solution to
 the problem you are presenting?
 
 If you are referring to the population of an IN statement then you
 could use iterate.
 
 Brandon
 
 On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:
 
  For example,   for Oracle in list limitation while using
 
  select * from abc
  where a in ('a', 'b', 'c', ...)
 
  We need to use a Custom tag for this.
 
  Thanks
 
 
  -Original Message-
  From: Larry Meadors [mailto:[EMAIL PROTECTED]
  Sent: Thursday, May 12, 2005 5:21 PM
  To: ibatis-user-java@incubator.apache.org
  Subject: Re: Custom Tag
 
  A couple?
 
  Check again.
 
  That is an interesting idea though.
 
  Larry
 
  PS: Please do not reply to other posts with new topics.
 
 
  On 5/12/05, Ming Xue [EMAIL PROTECTED] wrote:
  
   Hi
  
   I am very much amazed by Ibatis's ability to generate dynamic sql, which
  is blank in Hibernate.  There are a couple predefined tags provided by
  default,  But,  does the framework support  Custom Tags? if so, how can I
  attched them to the FrameWork?