Re: Way to use sql in mapper interface, without having to create a corresponding xml mapping file?

2010-05-13 Thread Rick R
On Thu, May 13, 2010 at 4:50 PM, Larry Meadors larry.mead...@gmail.comwrote: He wants to represent that in the xml config. Right. It seems odd that you can manually add the Mapper through Java (as Jeff has shown), but not through the xml config.

Re: Way to use sql in mapper interface, without having to create a corresponding xml mapping file?

2010-05-13 Thread Rick R
13, 2010 at 5:10 PM, Rick R ric...@gmail.com wrote: On Thu, May 13, 2010 at 4:50 PM, Larry Meadors larry.mead...@gmail.comwrote: He wants to represent that in the xml config. Right. It seems odd that you can manually add the Mapper through Java (as Jeff has shown), but not through

Re: Way to use sql in mapper interface, without having to create a corresponding xml mapping file?

2010-05-13 Thread Rick R
On Thu, May 13, 2010 at 9:21 PM, Rick R ric...@gmail.com wrote: (By the way, I'm searching the archives for this, and it's sort of off-topic but since you mentioned you create your datasource in XML - I'm curious how do you declare the pool implementation that you want to use? I know ibatis

Way to use sql in mapper interface, without having to create a corresponding xml mapping file?

2010-05-12 Thread Rick R
Larry showed me his cool no xml config setup which I'd love to implement at some point. For this current project using ibatis3 it's too late to refactor a real lot at this stage and we're using your typical sqlMapConfig file. Overall we still prefer to code all of our sql in xml files, but I

RE: SqlSession.close() without committing

2010-04-07 Thread Rick . Wellman
Hey Clinton, You've got volunteers coming out of the woodwork ;-) -Original Message- From: Martin Ellis [mailto:ellis@gmail.com] Sent: Wednesday, April 07, 2010 11:43 AM To: user-java@ibatis.apache.org Subject: Re: SqlSession.close() without committing One thing I'd have liked to

what happened to queryForMap?

2010-03-19 Thread Rick R
list, but hey it was one less step I had to do using ibatis queryForMap) -- Rick R

Re: what happened to queryForMap?

2010-03-19 Thread Rick R
On Fri, Mar 19, 2010 at 8:08 PM, Clinton Begin clinton.be...@gmail.comwrote: It was liquidated. Honestly I thought it was messy... but maybe I underestimated its usefulness... Well, most times I'm using it are for when I have a nested structure defined defined by a parentID column in the same

why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
I'm now starting to get into using ibatis3 more and I'm curious about why a 'roll up' is happening (based on a column I didn't mention as a rollup column) when I use an association. I'm sure it's something stupid I'm missing but I don't see it. For example this flat structure works just fine, and

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
, av.requiredFlag FROM Clinton On Sun, Feb 21, 2010 at 5:55 PM, Rick R ric...@gmail.com wrote: I'm now starting to get into using ibatis3 more and I'm curious about why a 'roll up' is happening (based on a column I didn't mention as a rollup column) when I use an association. I'm sure

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
On Sun, Feb 21, 2010 at 10:50 PM, Clinton Begin clinton.be...@gmail.comwrote: Oh... also put an id element on the parent (likee parentValueID?). Ok that's even more weird now. When I changed: result column=parentValueID property=parentValueID jdbcType=INTEGER / to id property=parentValueID

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
On Sun, Feb 21, 2010 at 11:26 PM, Guy Rouillier guyr-...@burntmail.comwrote: On 2/21/2010 11:19 PM, Rick R wrote: To Guy's point, not sure if the object's I'm mapping to matter? but if so: Objects look fine. How are you storing the collection of objects? As a List? Because if you

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
()); stream.processAnnotations(className); return (T) stream.fromXML(istream); } On Sun, Feb 21, 2010 at 11:36 PM, Guy Rouillier guyr-...@burntmail.comwrote: On 2/21/2010 11:19 PM, Rick R wrote: To Guy's point, not sure if the object's I'm mapping to matter? but if so: public class

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
And those static methods will be moved to a Helper file:) it's not my code:) On Sun, Feb 21, 2010 at 11:43 PM, Rick R ric...@gmail.com wrote: BaseModel just has some utility things mostly for XStream (I do also have XStream annotations on my model classes, but I wouldn't think that should

Re: why is ibatis rolling up for an association, not sure why this isn't flat, or what its rolling up on?

2010-02-21 Thread Rick R
On Mon, Feb 22, 2010 at 12:03 AM, Clinton Begin clinton.be...@gmail.comwrote: The reason is that the rows aren't uniquely identified. Upon a second look, I see that the column I recommended isn't unique. Which columns uniquely identify each parent row? They'd be unique by a combination of

If all my sql is in xml, do I gain that much (assuming unit tests) using Mapper objects as well?

2010-02-17 Thread Rick R
and simply going after the sql the old way... session.update(fooBar.updateEmployee, obj) ? (I read pages 53/54 of the guide and nothing jumped out at me as a huge gain in our case using Mapper classes.) I just don't want to be overlooking anything. -- Rick R

Re: If all my sql is in xml, do I gain that much (assuming unit tests) using Mapper objects as well?

2010-02-17 Thread Rick R
On Wed, Feb 17, 2010 at 2:51 PM, Jeff Butler jeffgbut...@gmail.com wrote: Using a mapper interface means you have a bit less code to write How is it less code?, that's my whole point in dropping it since I think it adds more code (for in our case seemingly little gain.) All my sql is in xml

Re: If all my sql is in xml, do I gain that much (assuming unit tests) using Mapper objects as well?

2010-02-17 Thread Rick R
On Wed, Feb 17, 2010 at 4:09 PM, Jeff Butler jeffgbut...@gmail.com wrote: In my case, it's a bit less code: Mapper interface: ListMyObject getByCompoundKey(@Param(id1) Integer id1, @Param(id2) Integer id2); Ah I see. That's an excellent point! I hadn't thought of that. In our case 99% of

now with ibatis3 - which sybase driver? - because of this issue

2010-02-11 Thread Rick R
Using the standard jconn3 sybase driver (the jtds driver is fine), I'm getting this error when attempting to get a List the following way without only adding default stuff (username, etc) SqlSession session = SqlSessions.metaDbSessionFactory.openSession(); SampleMapper mapper =

Re: iBatis 3.0 minimal complete example

2010-02-10 Thread Rick R
On Tue, Feb 2, 2010 at 9:27 AM, Clinton Begin clinton.be...@gmail.comwrote: I agree, that it's long overdue. Perhaps it's time for Jpetstore 6. And without leveraging Guice or Spring :)

Re: iBatis 3.0 minimal complete example

2010-02-10 Thread Rick R
On Wed, Feb 10, 2010 at 11:18 PM, Zoran Avtarovski zo...@sparecreative.com wrote: To be honest I think the choice of front end matters little. The key aspect is the data layer - IB3 and any dependency injection used. I think one example using spring and another using Guice is more than

RE: How would you - the experts - design this?

2010-01-25 Thread Rick . Wellman
I am not even sure this is worth two-cents but: What (for lack of a better word) confuses me is the phrase generate a jar file that will pull out some of the data... From what I can decipher, I would handle it like this. As you say, your data model itself is identical but the second application

RE: logging sql statements

2009-12-14 Thread Rick . Wellman
iBatis relies on logging of the underlying JDBC statements which is documented (somewhere). We use the following settings in our log4j.xml file, adjust to your liking: !-- iBATIS SQL statements -- category name=java.sql priority value=info / /category category

RE: IBatis 3 Exceptions

2009-12-04 Thread Rick . Wellman
Agreed on both points below... but am curious to the community at large... has anyone come up with something useful to do on a database exception other than apologize to the user? This might be a good forum to share. From: Clinton Begin [mailto:clinton.be...@gmail.com] Sent: Thursday,

RE: NoSuchMethodError in iBatis with applet

2009-11-25 Thread Rick . Wellman
I would guess this is more applet related than iBatis. i.e. Do any of the applet JARs contain your SQLMapConfig file? Or are you assuming that it has access to the filesystem (because an applet does not have access to the filesystem unless you explicitly configure it so). This is just my first

RE: Potential connection problem when using managed transactions in iBATIS 3

2009-11-19 Thread Rick . Wellman
Even if it is not an issue, I think it is usually good form to include your solution to a problem when you post. Not just hey, *I* solved *my* problem, so good luck with yours. From: Poitras Christian [mailto:christian.poit...@ircm.qc.ca] Sent: Thursday, November 19, 2009 7:38 AM To:

RE: Ibatis + apache BasicDataSource + Spring DAO + autocommit

2009-10-23 Thread Rick . Wellman
Welcome to my world. I recently trudged down this road myself and found the help/warnings in this area lacking (readers: PLEASE feel free to point out web documentation to refute me on that statement!). As there are six items in your stack (ibatis + BasicDataSource + Spring DAO +

RE: static SqlMapClient and transaction isolation problem

2009-10-22 Thread Rick . Wellman
Unfortunately I cannot dive into the many details of iBatis and transactions but here is how I would answer your question: 1) You almost assuredly want to create a single static SqlMapClient to service many threads. 2) I am pretty sure that iBatis uses ThreadLocal to isolate transactions from

RE: iBatis - Connections to PostgreSQL Not Closing

2009-10-19 Thread Rick . Wellman
Are they simply the other connections in the connection pool? -Original Message- From: Jim Borland [mailto:jborl...@calpoly.edu] Sent: Saturday, October 17, 2009 10:04 PM To: user-java@ibatis.apache.org Subject: iBatis - Connections to PostgreSQL Not Closing I have a Java application

RE: iBatis - Connections to PostgreSQL Not Closing

2009-10-19 Thread Rick . Wellman
Since I have some time over lunch: 1) I agree with Larry's reply below 2) At the risk of embarrassing myself on this forum, see below for my reply to your comments and questions: [your-code-sample-was-here] [your-comments-were-here] I've been wrestling with this problem for a long time and right

RE: How to configure SqlMapClient for multiple Oracle RAC services?

2009-10-15 Thread Rick . Wellman
I may be overstepping my overall iBatis knowledge but here is my understanding: 1) The workhorse of iBatis is the SqlMapClient object which is configured through an iBatis XML file (and you may be using Spring configuration as well, sounds like it). 2) The XML file defines one, and only one,

RE: Password Encryption

2009-10-15 Thread Rick . Wellman
Depending on the DataSource you are using, you might be able extend that class to override a particular property/method call. Can you describe your iBatis configuration? (i.e. sqlMap.xml, are you using Spring, what datasource are you using) From: Ejaz X Mohammed

RE: Password Encryption

2009-10-15 Thread Rick . Wellman
I needed to use the following technique to solve a similar challenge recently and, though seemingly obvious, I found no references on the web. I cannot give it a full stamp of approval but it is working for us so far: 1) Extend the iBatis class SimpleDataSourceFactory: public class

RE: How to configure SqlMapClient for multiple Oracle RAC services?

2009-10-14 Thread Rick . Wellman
(from the way you wrote your question) Assumption #1: You have N web-applications that each have their own Spring 'applicationContext.xml' file. Assumption #2: Until now, each configLocation property of the sqlMapClient bean has been identical. If Assumptions #1 and #2 are correct, then you have

RE: [ibatis 3] insert return generated id?

2009-10-13 Thread Rick . Wellman
I have not looked at the source you're referring to but did you deprecate the behavior or remove the behavior. I am not sure if you have a standing policy on things like this but here is my opinion: I understand the need to clean things up in a major release but I tend to favor formal

Re: Maven and iBatis 3.0 - Excuse me for the stupid question

2009-09-04 Thread Rick
On Thu, Sep 3, 2009 at 7:34 AM, Andy Law andy@roslin.ed.ac.uk wrote: Just to clarify, the xml files don't have to be at the top-level of the resources folder. You can impose a directory structure inside the resources folder too and so have the xml files in a directory on their own.

Re: Maven and iBatis 3.0 - Excuse me for the stupid question

2009-08-27 Thread Rick
On Thu, Aug 27, 2009 at 3:53 AM, Richard Bibb richard.b...@aimhedge.comwrote: The problem is, when under test how do I distinguish between the Mappers under test and those being used to do the testing? At the moment I only seem to be able to get things to work if I put all the Mapper.xml

Re: Maven and iBatis 3.0 - Excuse me for the stupid question

2009-08-27 Thread Rick
On Thu, Aug 27, 2009 at 3:53 AM, Richard Bibb richard.b...@aimhedge.comwrote: I'm probably being silly here as I don't seem to be able to figure out where to put my sqlMap XML files in my Maven project. I put them directly in the same package where I have my XYZMapper classes, so in your

Re: Maven and iBatis 3.0 - Excuse me for the stupid question

2009-08-27 Thread Rick
On Thu, Aug 27, 2009 at 3:07 PM, Brandon Goodin brandon.goo...@gmail.comwrote: non .java files that belong on the classpath are supposed to go under the resources directory in Maven. True. Brandon is right, you should put them there, otherwise you need to adjust your pom to include:

Re: iBATIS 3.0 selectOne SessionException if no data found

2009-08-26 Thread Rick
- To unsubscribe, e-mail: user-java-unsubscr...@ibatis.apache.org For additional commands, e-mail: user-java-h...@ibatis.apache.org -- Rick R

Re: [iBatis 3] insert/update via annotation w/ object example

2009-08-26 Thread Rick
On Wed, Aug 26, 2009 at 1:10 PM, Douglas Bell db...@boingo.com wrote: I’ve been through the user guide and the test cases but don’t see a good example of doing an insert or update with a Object using a annotation @Update(“INSERT INTO foo (bar_1, bar_2) VALUES (#{bar1}, #{bar2})”) void

Re: Newbie question: Update table that has no key / id

2009-08-25 Thread Rick
, e-mail: user-java-h...@ibatis.apache.org -- Thanks, Anoop -- Rick R

Re: Newbie question: Update table that has no key / id

2009-08-25 Thread Rick
, Aug 25, 2009 at 3:02 PM, Rick ric...@gmail.com wrote: no clue what your table looks like but this doesn't seem right: iamsId for both? where iams_id = #old.iamsId:VARCHAR# // and isactive=#old.iamsId:VARCHAR# On Tue, Aug 25, 2009 at 2:29 PM, Anoop

I don't see this in the ibatis3 docs - how to use different datasource implementations without jndi?

2009-08-23 Thread Rick
If I want to configure ibatis3 to use a different datasource (c3p0 for instance), how do I do that in the config.xml datasource section without having to configure it through JNDI? -- Rick R - To unsubscribe, e-mail: user-java

Re: confusing on caching prepared statements with datasource and openSession?

2009-08-23 Thread Rick
avoided the problem. 99% of the gain with psmt caching is in loops in a single thread anyway Clinton On Sun, Aug 23, 2009 at 2:23 PM, Rick ric...@gmail.com wrote: I thought that most datasources allow you to cache preparedStatements at the datasource level, so I'm confused what affect

clarification on docs pg 53 transaction control methods

2009-08-23 Thread Rick
pg 53 Tansaction Control Methods By default iBATIS does not actually commit unless it detects that the database has been changed by a call to insert, update or delete. If you’ve somehow made changes without calling these methods, then you can pass true into the commit and rollback methods to

Help creating a Guice TransactionInterceptor

2009-08-22 Thread Rick
Just wondering if anyone has worked on a Guice transaction interceptor yet for i3 ? My progress so far... I want to avoid: public FooBar update(FooBar fooBar) { SqlSession session = sqlSessionFactory.openSession(ExecutorType.REUSE); try { FooBarMapper mapper =

A GenericDao ? and a few rambling thoughts...

2009-08-20 Thread Rick
According to the i3 docs it looks like for just a simple 'get' of a blog you'd need something like: Blog blog = null; SqlSession session = sqlSessionFactory.openSession(); try { BlogMapper mapper = session.getMapper(BlogMapper.class); blog = mapper.selectBlog(id); } finally {

Sybase. Another interesting date issue using jconnect vs jtds

2009-01-28 Thread Rick
using jconnect? -- Rick

Re: Sybase. Another interesting date issue using jconnect vs jtds

2009-01-28 Thread Rick
java.util.Date lastLoginDateTime I've tried TIMESTAMP in place of DATETIME, didn't seem to make a difference On Wed, Jan 28, 2009 at 3:08 PM, Rick ric...@gmail.com wrote: Maybe I'm setting things up wrong, but when I try to insert or update using java.util.Date the very last digit on the long

Re: Sybase. Another interesting date issue using jconnect vs jtds

2009-01-28 Thread Rick
OMG please DELETE THREAD DELETE THREAD RICK IS A MORON. RICK IS A MORON. IGNORE IGNORE IGNORE:) On Wed, Jan 28, 2009 at 3:38 PM, Rick ric...@gmail.com wrote: Crap, now I seem to be having the issue with the jtds driver also. Maybe I just get lucky sometimes and the dates just work. Most

Re: Sybase. Another interesting date issue using jconnect vs jtds

2009-01-28 Thread Rick
; On Wed, Jan 28, 2009 at 3:43 PM, Rick ric...@gmail.com wrote: OMG please DELETE THREAD DELETE THREAD RICK IS A MORON. RICK IS A MORON. IGNORE IGNORE IGNORE:) On Wed, Jan 28, 2009 at 3:38 PM, Rick ric...@gmail.com wrote: Crap, now I seem to be having the issue with the jtds driver also. Maybe I

Re: SqlMapConfig.xml and subsequent sqlMap entries

2009-01-24 Thread Rick
, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments. -- Rick

Re: 2 Way 1-1 relationship

2009-01-23 Thread Rick
On Wed, Jan 21, 2009 at 12:34 PM, Petr V. greatman...@yahoo.com wrote: Thanks Ingmar Lötzsch for the reply. Actually I was simplifying the context from 1-M to 1-1 for discussion so left groupBy attribute mistakenly. The problem at hand is that Teacher has students (1:M). Student must have

Re: ibatis db pool or dbcp

2009-01-20 Thread Rick
On Tue, Jan 20, 2009 at 8:38 AM, Clinton Begin clinton.be...@gmail.com wrote: PS: If you're using an application server, my recommendation is to use the container managed DataSource... always always always... I'm just curious why? Is it because of possible monitoring tools (like maybe a

Re: [SURVEY] How many connections are in your pool?

2009-01-20 Thread Rick
)? 3. If you have 2x or 3x more connections than you do CPUs, do you have a reason that you could share? Cheers, Clinton -- Rick

Re: ibatis db pool or dbcp

2009-01-19 Thread Rick
On Sun, Jan 18, 2009 at 2:22 PM, Zsolt Koppany zkoppanyl...@intland.com wrote: Hi, which database pool is recommended for production usage? The pool shipped with ibatis or dbcp? We use ibatis 2.3.4.726. I'm curious about this also. I heard the ibatis common pool is fine for production. Are

Re: Nested attributes / class instances and PropertyClass.

2009-01-19 Thread Rick
the iBATIS - User - Java mailing list archive at Nabble.com. -- Rick

Re: performance hit if not declaring parameterClass in sqlMap definitions?

2009-01-19 Thread Rick
dang I hate gmail sometimes. I need to remove this address.. I keep meaning to send to the user list and often start typing 'ibatis..' in gmail and this comes up first. Sorry about that. On Mon, Jan 19, 2009 at 9:24 PM, Rick ric...@gmail.com wrote: I usually leave off naming the parameter class

performance hit if not declaring parameterClass in sqlMap definitions?

2009-01-19 Thread Rick
I usually leave off naming the parameter class in my sqlMap definitions. Is there a performance hit leaving off this declaration? -- Rick

Re: Sybase issue... TEXT column when null insert/updates fail, but when defined as VARCHAR nulls work?

2009-01-17 Thread Rick
); } } And register it as follows: typeHandler javaType=java.lang.String jdbcType=LONGVARCHAR callback=com.ClobTypeHandlerCallback / I hope this helps you. Rick ric...@gmail.com 01/16/2009 02:45 PM Please respond to user-java@ibatis.apache.org To ibatis-user-j...@incubator.apache.org

Re: Sybase issue... TEXT column when null insert/updates fail, but when defined as VARCHAR nulls work?

2009-01-17 Thread Rick
and copy and pasting:) On Sat, Jan 17, 2009 at 9:59 AM, Rick ric...@gmail.com wrote: Thanks for this Christopher. Interestingly, I tried out the jtds driver and it allowed the null inserts on TEXT datatype. . (Then again jtds had the problem with the DATE field, putting things in off a few

Sybase issue... TEXT column when null insert/updates fail, but when defined as VARCHAR nulls work?

2009-01-16 Thread Rick
, but if the field is null, Sybase complains when it's declared as a TEXT (or CLOB) ( #spec:TEXT# ). Yet if I change it to VARCHAR the null value is accepted and the insert/update works. Shouldn't TEXT jdbc type work for all phases of the CRUD? -- Rick

Is this simple DAO approach sufficient?

2009-01-12 Thread Rick
I understanding I'm bind my DAOs to a particular sqlmap config being loaded, but other than some 'purist' unit testing issues, what's wrong with this simple approach (I'll have a couple different base DAOs that will load a different config file because going against a different DB.) public

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
with writing a little plumbing code yourself and just being done with it? Jeff Butler On Fri, Jan 9, 2009 at 10:34 AM, Rick ric...@gmail.com wrote: I'm curious about your thoughts on using the ibatis DAO over the Spring stuff? I'm really only using Spring for being able to extend

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
ibatis layer? I don't want SpinalTap answer Well, this one goes to a 11. :) On Mon, Jan 12, 2009 at 2:10 PM, Chris O'Connell oconn...@gorillachicago.com wrote: Rick, I certainly understand your point (and I'm not trying to be combative), but I think you are asking the wrong question. You can

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
On Mon, Jan 12, 2009 at 2:44 PM, Sundar Sankar fatboys...@gmail.com wrote: The way I see it, Instead of packaging the daos and ibatis jars, You would package the daos, and service and other jars together and make it reusable. In one of my earlier projects, I had a central bootstrap, that was

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
On Mon, Jan 12, 2009 at 4:08 PM, Sundar Sankar fatboys...@gmail.com wrote: Yes. Our project did take configurable prop files. But it didnt do just that. But looks like your need is to take a prop file and return an object after hitting the db the prop file points to. Spring wouldnt be

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
On Mon, Jan 12, 2009 at 5:42 PM, Sundar Sankar fatboys...@gmail.com wrote: I guess I missed this one. But why do u need to use applicationContext.getBean. Those are ancient man. With Spring Annotations (check the 2.5+ documentation), U hardly need xmls and all of this crappy code. Yes you did

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-12 Thread Rick
On Mon, Jan 12, 2009 at 4:50 PM, Sundar Sankar fatboys...@gmail.com wrote: By reinventing I was talking of , connection pool / management, transaction management etc etc. Transaction demarcation in Spring is sort of nice. I will give it a plus for that (Although I like it even better in EJB3.)

Re: Using ibatis in a standalone jar with Spring, and also using spring in web tier

2009-01-10 Thread Rick
unless you know out of the gate that you're going to have multiple persistence frameworks or databases. Cheers, Clinton On Fri, Jan 9, 2009 at 12:07 AM, Rick ric...@gmail.com wrote: I've looked at guice. I was liking using the SqlMapClientTemplate from spring. I really don't even need Spring

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-10 Thread Rick
.) So I'm curious how you are saying guice can handle this, if it even can. -- Rick

Way to declare transactionManager section in a separate file and have it picked up?

2009-01-10 Thread Rick
-- Rick

iBATIS DAO vs SqlMapClientDaoSupport

2009-01-09 Thread Rick
I'm curious about your thoughts on using the ibatis DAO over the Spring stuff? I'm really only using Spring for being able to extend SqlMapClientDaoSupport. I'm not doing anything super cool with swapping out test dao's etc with a different implementation, so I'm thinking using the preferred

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-09 Thread Rick
On Fri, Jan 9, 2009 at 2:25 PM, Jeff Butler jeffgbut...@gmail.com wrote: iBATIS DAO is deprecated, so probably won't be enhanced, may not work with future version of iBATIS, etc. But it works perfectly well as a simple IoC type of container with a bent towards iBATIS. Spring is cool but

Re: iBATIS DAO vs SqlMapClientDaoSupport

2009-01-09 Thread Rick
On Fri, Jan 9, 2009 at 2:47 PM, Jeff Butler jeffgbut...@gmail.com wrote: I meant that you could write plumbing code to support whatever you want your persistence interface to look like. Spring SqlMapClientDaoSupport is IoC enabled, and also supports Spring's translation of SQLException into

Problem having persistence code with ibatis as a complete stand-alone jar with Spring and still use spring in web tier

2009-01-08 Thread Rick
This is really more of a Spring question I guess, but I'll ask here first. I want to have all my persistence classes (services and daos) that use ibatis to be bundled in a standalone jar that my war (or possibly multiple wars in an ear) can use. I'm using Spring for mSqlMapClientDaoSupport and

Using ibatis in a standalone jar with Spring, and also using spring in web tier

2009-01-08 Thread Rick
that I could get the beans defined in my persistence jar initialized and then somehow used within my webapp classes? I'm confused how to set this stuff up. Debating about just ditching using Spring for my persistence jar. -- Rick

Re: Using ibatis in a standalone jar with Spring, and also using spring in web tier

2009-01-08 Thread Rick
I meant spring-context not application-context, you know the spring config file:) On Fri, Jan 9, 2009 at 12:29 AM, Rick ric...@gmail.com wrote: This is really more of a Spring question I guess, but I'll ask here first. I want to have all my persistence classes (services and daos) that use

Re: Using ibatis in a standalone jar with Spring, and also using spring in web tier

2009-01-08 Thread Rick
Sheesh look at this article... http://springtips.blogspot.com/2007/09/using-shared-context-from-ejbs.html it gives me a headache. How the heck can anyone justify using Spring if you need to do the kind of stuff mentioned in that article. What a royal pain. On Fri, Jan 9, 2009 at 12:31 AM, Rick

Re: Using ibatis in a standalone jar with Spring, and also using spring in web tier

2009-01-08 Thread Rick
.) I'll look how The Pet Store does things and try that approach I suppose. Is the Pet Store considered a good practice to follow? On Fri, Jan 9, 2009 at 12:56 AM, Nathan Maves nathan.ma...@gmail.com wrote: If all you need is DI check out guice. On Thu, Jan 8, 2009 at 10:49 PM, Rick ric

Re: Problem having persistence code with ibatis as a complete stand-alone jar with Spring and still use spring in web tier

2009-01-08 Thread Rick
in the jar file. In your webapp/ear that you are including the jar in I configured spring to use multiple config files. have you tried that? On Thu, Jan 8, 2009 at 10:26 PM, Rick ric...@gmail.com wrote: This is really more of a Spring question I guess, but I'll ask here first. I want

Re: Problem having persistence code with ibatis as a complete stand-alone jar with Spring and still use spring in web tier

2009-01-08 Thread Rick
On Fri, Jan 9, 2009 at 2:10 AM, Rick ric...@gmail.com wrote: I'll have to mess with it some more, maybe the problem is the config file in my jar has the same name as the one in my webapp classpath. That was my problem. Thanks Nathan. You got me on the right track. (Hopefully when this becomes

[OT sort of] If using Tomcat, what would you use to hook into slqlmapclient flushDataCache (and change logging)?

2008-12-26 Thread Rick
people create hooks into their app by other means? Is the easiest just to create some protected admin page as part of your webapp and just hook into a servlet to make the calls? What is the approach most take when they want to accomplish the above tasks using a simple appserver? Thanks -- Rick

[OT sort of] If using Tomcat, what would you use to hook into slqlmapclient flushDataCache (and change logging)?

2008-12-26 Thread Rick
people create hooks into their app by other means? Is the easiest just to create some protected admin page as part of your webapp and just hook into a servlet to make the calls? What is the approach most take when they want to accomplish the above tasks using a simple appserver? Thanks -- Rick

Re: Trying to use HashMap as a param object for an UPDATE - getting an exception

2008-12-15 Thread Rick
On Sun, Dec 14, 2008 at 11:02 AM, Larry Meadors larry.mead...@gmail.com wrote: On Sat, Dec 13, 2008 at 8:09 PM, Clinton Begin clinton.be...@gmail.com wrote: That said, (to further argue with myself), I actually prefer the flexibility of not typing the statement. It's a sort of duck typing for

Re: Sybase sucks... I'm just sayin

2008-12-05 Thread Rick
the only option for us. (Other than the fact that we work at Sybase and really like and want to keep our jobs) Chris Mathrusse [EMAIL PROTECTED] Sybase, Inc One Sybase Drive Dublin, CA 94568 (925) 236-5553 Rick [EMAIL PROTECTED] 12/05/2008 03:38 PM Please respond to user-java

Re: Best practice for using Ibatis in Web application

2008-12-03 Thread Rick
:00 AM, Larry Meadors [EMAIL PROTECTED] wrote: I'm looking at google guice + stripes + ibatis (ashamed to say it was Brandon and Nathan's idea though). Virtually zero configuration. It just works. Larry -- Rick

Re: Define Hashmap

2008-12-01 Thread Rick
2008/12/1 John Chien [EMAIL PROTECTED] Dear sir: This is my first time of using HashMap. I defined the following structure and statement. Are they correct ? What is the key for the HashMap ? resultMap id=facilityIdBEAN class=java.util.HashMap result property=facilityId

Re: Am I missing something really simple? Way to avoid adding all props in a map if I decide to add one extra collection to pojo

2008-11-18 Thread Rick
/ result property=address resultClass=Address/ /resultMap for: BusinessEntity { String name; String abbreviation; Integer id; //..etc Address address ListAssociate associates } On Mon, Nov 17, 2008 at 10:56 AM, Rick [EMAIL PROTECTED] wrote: Hopefully I'm just being a newb

Re: Am I missing something really simple? Way to avoid adding all props in a map if I decide to add one extra collection to pojo

2008-11-18 Thread Rick
On Tue, Nov 18, 2008 at 12:44 PM, Kai Grabfelder [EMAIL PROTECTED] wrote: I don't think that this is currently possible. I don't really mind writing result maps, as I'm generating most of them with abator. Yea, I'm currently doing the same (using ibator to create my mappings), but I still

Re: Am I missing something really simple? Way to avoid adding all props in a map if I decide to add one extra collection to pojo

2008-11-18 Thread Rick
On Tue, Nov 18, 2008 at 3:43 PM, Raymond McDermott [EMAIL PROTECTED] wrote: iBatis supports automatically mapping in beans where the property names match the getters/setters so you are in luck ;-) I understand that but that ONLY works for when you are mapping one statement to a class. Look at

Re: ibator.. disable all the comments in pojos?

2008-11-16 Thread Rick
the time to enable this function outside of Eclipse. I intend to make it an intentional, thoughtful, and somewhat difficult process to turn them off. Sorry...sort of. It's generated code! Why do you care what it looks like? Jeff Butler On Sun, Nov 16, 2008 at 7:55 PM, Rick [EMAIL PROTECTED

Question on doing things the Flat way

2008-11-15 Thread Rick
I was going to mail this directly to a few of my buds, but figured whatever the response is, it could be useful for others... First the business requirements: //hypothetical example for sake of this email: 1) Show a single person and their favorite cars and display the person's rank of each car

Just curious...how 'much' worse is performance if just maps

2008-11-15 Thread Rick
name (getXXX is easier than having to keep the datamodel open and remembering the exact column name, and ooops someone forgot a unit test.) -- Rick

iBATIS with Tomcat vs JBoss

2008-11-03 Thread Rick
users all at the same time when they login to try to get a list of reports available to them at 3PM. Are there some major performance gains I'll get using JBoss over Tomcat? Tomcat over JBoss? Are there any other issues I should consider before I make the switch? Thanks -- Rick

Fw: Help with HashMap

2007-07-03 Thread Rick Accountius
Larry, I switched to a LinkedHashMap and that appears to have worked. I tried some of my other queries too, and they appear to work as well. UDAMAN! Thanks!! Rick Accountius Internet: [EMAIL PROTECTED]

Help with HashMap

2007-07-02 Thread Rick Accountius
the same Ibatis select statement to service arbitrary SQL statements. Hope I'm making sense. select id=getReport parameterClass=com.ibm.bean.ReportDefinition resultClass=java.util.HashMap remapResults=true $query$ /select Thanks, Regards, Rick Accountius Internet: [EMAIL PROTECTED]

Re: Help with HashMap

2007-07-02 Thread Rick Accountius
Thanks Nathan! Not the answer I was hoping for, but it does make sense. Guess I should have looked at the Java API to begin with. DOH! Thanks again. Rick Accountius Internet: [EMAIL PROTECTED] Nathan Maves [EMAIL PROTECTED] 07/02/07 03:48 PM Please respond to user-java

Re: Questions on allowing users to switch to a different datasource

2006-12-04 Thread Rick Reumann
That'll be perfect. Thanks Clinton. On 12/1/06, Clinton Begin [EMAIL PROTECTED] wrote: Hi Rick, You can use: Properties properties = new Properties(); properties.setProperty(DataSourceName); SqlMapClientBuilder.buildSqlMap Client (reader, properties); Then in the SqlMapConfig.xml file

Employee self-join one to many relationship (iBatis)

2006-07-03 Thread Rick
I just want to use iBatis in the cleanest way possible. I have a workaround but wonder if iBatis support self-joined one to many relationships. Let me explain. I have a query that returns employees. Employees have Bosss who are Employees. Currently I have Employees have

  1   2   >