ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Query to insert multiple data in Oracle through ESQL

Post new topic  Reply to topic
 Query to insert multiple data in Oracle through ESQL « View previous topic :: View next topic » 
Author Message
varshasvin
PostPosted: Mon May 12, 2008 2:41 am    Post subject: Query to insert multiple data in Oracle through ESQL Reply with quote

Newbie

Joined: 27 Feb 2008
Posts: 9

Anybody knows the syntax of query to insert multiple rows in the database?

I have tried following query in Database System :

Insert into STG_OUTPUT (SYSTEM_ID,SEQUENCE_ID,ITEM_CODE)(select SourceSystem,Accounting_Doc_Line_Item_No,Line_Item_Code from Environment.Variables.OutputLineItem);

This query is running into database directly but the same query is not running through ESQL code. When added this statement in ESQL its giving Syntax error to that line.

Please help me for this. What is the correct syntax for inserting multiple rows in database through ESQL?
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon May 12, 2008 2:52 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

use PASSTHRU functionality to execute the same SQL on MB(ESQL)


Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
varshasvin
PostPosted: Mon May 12, 2008 3:02 am    Post subject: Inserting Batch of data into database Reply with quote

Newbie

Joined: 27 Feb 2008
Posts: 9

I have tried with PASSTHRU but...that is also giving runtime exception that "Invalid Database specification "

Can u tell me any other way to insert the Batch or chunks of data into database.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon May 12, 2008 3:07 am    Post subject: Re: Inserting Batch of data into database Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

varshasvin wrote:

"Invalid Database specification "


This is a different issue, you could be given some wrong database name

Post the PASSTHRU ESQL statement here

Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
varshasvin
PostPosted: Mon May 12, 2008 3:19 am    Post subject: Reply with quote

Newbie

Joined: 27 Feb 2008
Posts: 9

PASSTHRU 'Insert into STG_ZGLUPLOAD_OUTPUT (SYSTEM_ID,SEQUENCE_ID,ITEM_CODE)(select SourceSystem,Accounting_Doc_Line_Item_No,Line_Item_Code from Environment.Variables.OutputLineItem)' TO Database.{ext_chr_InputDB}.{ext_chr_InputSchema}.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon May 12, 2008 5:38 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Just try this

PASSTHRU('INSERT INTO STG_ZGLUPLOAD_OUTPUT (SYSTEM_ID,SEQUENCE_ID,ITEM_CODE)
(select SourceSystem,Accounting_Doc_Line_Item_No,Line_Item_Code from ?) TO Database.{?}.{?}' ,
Environment.Variables.OutputLineItem,
ext_chr_InputDB,
ext_chr_InputSchema)

Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Query to insert multiple data in Oracle through ESQL
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.