Return-Path: X-Original-To: apmail-camel-dev-archive@www.apache.org Delivered-To: apmail-camel-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4C1C4118D4 for ; Wed, 20 Aug 2014 07:19:40 +0000 (UTC) Received: (qmail 65153 invoked by uid 500); 20 Aug 2014 07:19:40 -0000 Delivered-To: apmail-camel-dev-archive@camel.apache.org Received: (qmail 65108 invoked by uid 500); 20 Aug 2014 07:19:40 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Delivered-To: moderator for dev@camel.apache.org Received: (qmail 29039 invoked by uid 99); 20 Aug 2014 07:03:05 -0000 X-ASF-Spam-Status: No, hits=2.5 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,SPF_SOFTFAIL,T_FILL_THIS_FORM_SHORT,URI_HEX X-Spam-Check-By: apache.org Received-SPF: softfail (athena.apache.org: transitioning domain of noorul11@gmail.com does not designate 216.139.236.26 as permitted sender) Date: Wed, 20 Aug 2014 00:02:40 -0700 (PDT) From: "noorul11@gmail.com" To: dev@camel.apache.org Message-ID: <1408518160770-5755420.post@n5.nabble.com> In-Reply-To: References: <1408448018099-5755388.post@n5.nabble.com> Subject: Re: Sub Query is not working with SQL Server MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Which Camel component? camel-jdbc Which version? camel version 2.13.0 Can you share your route? {{customer.emailid}} SELECT distinct TOP 1 MOBILE,FAX,ADDRESS_EMAIL,(case when((select count(*) from urole where r_id = 3 and U_ID = ID)>0) then 1 else 0 end as ROLE, case when((select count(*) from urole where r_id = 4 and u_id = ID) > 0) then 1 else 0 end as ADMIN, case when((select count(*) from urole where r_id = 2 and u_ID = ID)>0) then 1 else 0 end as VENDOR, case when((select count(*) from urole where r_id =9 and u_id = ID)>0) then 1 else 0 end as NO_SURVEY_FLAG) from myuser where ADDRESS_EMAIL = :?emailID ${body} -- View this message in context: http://camel.465427.n5.nabble.com/Sub-Query-is-not-working-with-SQL-Server-tp5755388p5755420.html Sent from the Camel Development mailing list archive at Nabble.com.