Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 79183 invoked from network); 24 Dec 2008 09:49:30 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 24 Dec 2008 09:49:30 -0000 Received: (qmail 62924 invoked by uid 500); 24 Dec 2008 09:49:28 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 62911 invoked by uid 500); 24 Dec 2008 09:49:28 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 62902 invoked by uid 99); 24 Dec 2008 09:49:28 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Dec 2008 01:49:28 -0800 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [212.235.41.9] (HELO se01.solaredge.local) (212.235.41.9) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Dec 2008 09:49:20 +0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4325 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C965AC.D874A6F3" Subject: insert statement Date: Wed, 24 Dec 2008 11:48:59 +0200 Content-Transfer-Encoding: 7bit Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: insert statement Thread-index: AcllrNghL3827z8bT3+A4ujukpvyBg== From: "Gil Vernik" Importance: normal Priority: normal To: Spam: X-SpamInfo: helo-dns, X-Virus-Checked: Checked by ClamAV on apache.org This is a multi-part message in MIME format. ------_=_NextPart_001_01C965AC.D874A6F3 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hi there, I would like to write a dynamic insert statement, but both fields and values are dynamic. I mean=20 insert into table_one ( !!! dynamic list of keys from the HashMap ) values ( !!! values ); =20 I want both the list of column names and it's values to be filled automatically, depends on the parameterClass. How can I do it? I don't care to use something else, instead of java.util.Hashmap. =20 Thanks, Gil. =20 This message contains confidential information and is intended only for = the individual named. If you are not the named addressee you should not = disseminate, distribute or copy this e-mail. Please notify the sender = immediately by e-mail if you have received this e-mail by mistake and = delete this e-mail from your system. E-mail transmission cannot be = guaranteed to be secure or error-free as information could be = intercepted, corrupted, lost, destroyed, arrive late or incomplete, or = contain viruses. The sender therefore does not accept liability for any = errors or omissions in the contents of this message, which arise as a = result of e-mail transmission. If verification is required please = request a hard-copy version. ------_=_NextPart_001_01C965AC.D874A6F3 Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable

Hi there,

I would like to write a dynamic insert statement, = but both fields and values are dynamic.

I mean

<insert<= span style=3D'font-size:10.0pt;font-family:"Courier New"'> id=3D"someIDhere" parameterClass=3D"java.util.HashMap">

        insert into = table_one (

      =       !!! dynamic list of keys from the HashMap

        ) values = (

         &= nbsp;  !!! values

        = );

</insert>

 

I want both the list of column names and it’s = values to be filled automatically, depends on the parameterClass. How can I do it? I = don’t care to use something else, instead of java.util.Hashmap.

 

Thanks,

Gil.

 

This message contains = confidential information and is intended only for the individual named. = If you are not the named addressee you should not disseminate, = distribute or copy this e-mail. Please notify the sender immediately by = e-mail if you have received this e-mail by mistake and delete this = e-mail from your system. E-mail transmission cannot be guaranteed to be = secure or error-free as information could be intercepted, corrupted, = lost, destroyed, arrive late or incomplete, or contain viruses. The = sender therefore does not accept liability for any errors or omissions = in the contents of this message, which arise as a result of e-mail = transmission. If verification is required please request a hard-copy = version.

------_=_NextPart_001_01C965AC.D874A6F3--