bulk inserts from stored procedure

What is the best way to do bulk inserts from a SQL stored procedure or
one created by using C with embedded sql and host variables?

I need to call it from VB via ODBC

Does DB2 SQL handle arrays yet?

If anyone could point me to some examples that would be great!

Thanks in advance!

0
spoliskey (49)
11/30/2005 10:03:16 PM
comp.sys.ibm.as400.misc 9118 articles. 0 followers. Post Follow

0 Replies
256 Views

Similar Articles

[PageSpeed] 5
Reply:
Similar Artilces:

Bulk Loading into posgres 8.0.0
I'm trying to bulk load CVS data into my postgres database. All my data files contain a field header & most are quote enclosed. Is there an alternative for handling the optionally enclosed feature that does not exist for the COPY FROM? Is there any word on when COPY will be modified to support both COPY FROM and IGNORE REPLACE? Matt Sample Ultrasound L9 DFR/Warranty Champion GE Healthcare Technologies T 414.647.6540 F 414.647.4090 C 262.442.0028 D 8*767.6540 E matthew.sample@med.ge.com www.gehealthcare.com ---------------------------(end of broadca...

Apple retail store sales decline as consumers wait for new products
http://appleinsider.com/articles/14/05/05/apple-retail-store-sales-decline-as-consumers-wait-for-new-products -- MFB On 2014-05-20 11:04 PM, Flint wrote: > http://appleinsider.com/articles/14/05/05/apple-retail-store-sales-decline-as-consumers-wait-for-new-products > The CIC (caretaker in charge) has been a disaster. Every indicator has declined since he was appointed by Jobs before he passed, for the exception of yearly revenue which has been a whimper compared to the time that Jobs was in charge. ...

INSERT or MULTI INSERT
Hi, I am using oracle 9 r2. I am trying to INSERT the records from another table and I ahve to increment the sequence_num column but it's not incrementing and giving me a Unique Constraint error because sequence_num is a part of the composite PK with order_id. I have following table structure ================================= CREATE TABLE NR_ATG_ORDER ( ATG_ORDER_ID VARCHAR2 (40) NOT NULL, DIVISION_ID VARCHAR2 (2) NOT NULL, NOPS_ORDER_ID VARCHAR2 (12), CUSTOMER_ID VARCHAR2 (11), ... JOB_REF_NUMBER VARCHAR2 (12),...

SQL-Position after INSERT INTO ???
Hi All, I open a SQLTable with the ORDER BY -clausule. Then I add a new row "INSERT INTO ..." After this, the cursor is placed on the last row. If I look to the SDK, I find as one of the last statements: SELF:GoTo(SELF:nAppendRecNum) which is the last rownumber +1 This works correct if the table is not opened by a ORDER BY, otherwise the position is always the last logical row, which is not the row I have append. My table has an identifier column ID. How can I get the value of this column just after appending and before the SELF:GoTo() statement ? Is there ...

fprintf() insert new line character
Hi all, I have a large cell object which generally looks like this: {'[1 5 3]', 0.34534} {'[1 5 4]', 0.35332} {'[1 5 6]', 0.54345} ..... it is 131071 rows long. I am trying to save this data to disk. I can do this, but the file is all bunched up on one line and is a nightmare to look at. The procedure I am using for outputting is: output = fopen(destination, 'w'); for i = 1:length(input) a = input{i, 1}; b = input{i, 2}; fprintf(output, '%s, %s\n', a, b); end fclose(output); As I said, this works, but not as expected. Shouldnt the &...

Retrieving resultsets from oracle stored procedures via odbc
I created a stored procedure in oracle with the help of sql +plus: Set serveroutput on create or replace procedure spComp(company IN CHAR,oFname OUT CHAR, oFamname OUT CHAR, oAdr OUT CHAR, oTelno OUT CHAR) AS Cursor SelWorkers IS SELECT firstname, familyname, address, telno FROM customers WHERE company = 'Compname'; cnt NUMBER DEFAULT 1; BEGIN DBMS_OUTPUT.PUT_LINE('Employees of Companyname'); DBMS_OUTPUT.PUT_LINE('firstname familyname address telno'); FOR customers IN SelWorkers LOOP oFname := customers.firstname; ...

How to store current matrix in a variable?
Hello I'm writing a program where the user can freely move in a 3D-environment. However, there is one thing that I haven't solved yet: the user's orientation is based on world coordinates. This isn't good, because when e.g. the user looks down at -y and does a roll (about its longitudinal axis), he actually turns his heading in world coordinates. So I figured I just need an own matrix to store the user's current orientation, which then can be modified by simple glRotate*. But the problem is now: how can I get the result of the rotation for later retrieval? I could of cours...

memmanadd.pdf - ToC
Hi, The minimal example is quite long but should be self-explaining - taken from memmanadd.pdf, p.8 (24 of 56). I get (using miktex + winxp + latex/pdflatex): ! Missing control sequence inserted <inserted text> \inaccessible l.61 \renewcommand{cftchapterafterpnum} {} % ------------------- \documentclass[11pt,a4paper]{memoir} \usepackage[latin1]{inputenc} \usepackage[USenglish]{babel} \usepackage[T1]{fontenc} \newcommand{\bla}{bla bla bla bla bla bla bla. } \newcommand{\blabla}{\bla\bla\bla\bla\bla} \newcommand{\blablabla}{\blabla\blabla\bl...

How to pass a procedure as an argument
If got this code and it errors at line 2 at the (double (somefunction n) expression. If anyone can tell me why because I cannot figure it out. 1. (define (somefunction n) (+ n 1)) 2. (define (double (somefunction n)) (somefunction (somefunction n)) ) 3. (double (somefunction 1)) On 26 Jan 2007 16:56:19 -0800, "justmehere" <inderpaul_s@yahoo.com> wrote: >If got this code and it errors at line 2 at the (double (somefunction >n) expression. If anyone can tell me why because I cannot figure it >out. > >1. (define (somefunction n) (+ n 1)) > >2. (def...

Re: Create a dataset using no IO
> -----Original Message----- > From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On > Behalf Of Scott Bass > Sent: Monday, October 20, 2008 1:45 PM > To: SAS-L@LISTSERV.UGA.EDU > Subject: Re: Create a dataset using no IO - is there a SAS > bulk load PROC? > > <munch> > > > On a Unix platform by using a link, a file can have more > than one name. > > This makes it possible to have a file appear in many > locations without > > incurring any I/O or storage costs - in reality there's > only one copy on > > disk. (The f...

Compile-Time Checking for Insertion Rights on a C++ DOM Tree
While working on a DOM data structure, I noticed that only detached nodes and newly created nodes could be legally inserted into the tree. Having read a little about smart pointers and design-by- contract, I tried to enforce this condition by writing something analogous to: class Node { private: Node (std::string tag); // Clients: use Node::create() instead! ... public: static std::unique_ptr<Node> create(std::string tag); std::unique_ptr<Node> detach(); void insertNodeAsFirstChild(std::unique_ptr<Node> child); ... public: ...

RE: bulk update
I'd try something like a "create table as select" with all the modifications needed. "copy out" the temporary table. Drop the original base table and recreate it and do a bulk "copy in" and build any indexes. This does require a few minutes of downtime but you can test the time by building a 2nd temporary table. Updating large chunks would probably bring you to escalate to table locking and not allowing anyone to use the table. The above can be quite short, depending how quick your system is, how large is the tables, disks, how many locations etc. ...

What is the procedure for adding a spacer between layouts?
I can't remember how to do it. Looked in the documentation but it's not real clear to me. FMP 5.5 Mac. Thanks in advance! -- The Wolf <elvispmpsd@earthlink.net> wrote: > I can't remember how to do it. Looked in the documentation but it's not real > clear to me. > > FMP 5.5 Mac. > > Thanks in advance! Create a layout. In Layout Setup, change the layout name to a hyphen "-" After you exit the layout, you will only be able to revisit the layout by paging through the layouts in Layout mode using the rolodex. You can move it in the list us...

Gather Format and Store
The IT group that I work with has the habit of gathering data, formatting (i.e. in reports) and then storing the same formated data in the same database. I think the practice is wrong. I think the activity is fundamentally wrong because we are storing the exact same data in a database in two different locations. Somehow I have the impression that database design is about "oneness". I believe that collecting the data and then storing summerized data for reporting into a data warehouse would be the right solution. I am getting flack for my viewpoint. Am I all washed up? That soun...

Postgresql Bulk Loading
This is a multi-part message in MIME format. ------_=_NextPart_001_01C4432F.E2D6061A Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Does Postgresql have a bulk loading utility that allows you to load large amounts of data and doesn't write to log files (WAL files) ? I need to load over a gig of data a day and don't want it to write to logs. =20 =20 Thank you! =20 ~ Troy Campano ~ ------_=_NextPart_001_01C4432F.E2D6061A Content-Type: text/html; charset="us-ascii" Content-Transfer-Encodin...

Storing Thread events in a Vector
I have a thread (Producer) that is supposd to sleep for a random amount of time, record it in a vector and wake up another thread (Consumer). That thread should read the elements from the vector when the first thread (Producer) is done writing to it. So, can't figure out how to get the Consumer thread to see the elements in the vector. Right now it doesn't print anything because Consumer for some reason doesn't see the vector elements. Here's what I have: ----------------------------------------------------------------------- // Import libraries import java.util.Random; impo...

HELP Please!!! CHR$ NN and LF insertions in program converted to string on HP48??
Hello: When converting a program (i.e. << prgm...>> to a string on the hp48 what causes the "CHR$ NN <<prgm...(embedded LF char)...>>" phenomenon? I ask because one of my 48s does it yet another doesn't(one is VERSION M, the other is VERSION R). Is this dependent on the version of the calculator or flag settings? I've checked the flag settings and can't seem to find the cause. I've noted that in the AUR, under the ->STR command(p3-334) that it mentions: "...If the argument object is normally displayed intwo or more lines, the resu...

Need help on best way to insert many items quickly
Hi, My client has a product database od around 20000 items. And it is updated every few days when he gets a catalog from the supplier. It's supposed to work like this: if there already is a product in the database with that ID (primary key), just UPDATE the price, and if there is no product with that ID it should do an INSERT for that item. Now I've tried it in several ways and I can't seem to get it to execute in under 20 seconds (max execution time is 30s, so just to be sure). I've tried doing an update for every item (UPDATE product SET price=$price where ID=$id) and if...

Inserting Same Part in Assembly
Anyone know how i can insert the same part into holes that are linear patterened, without adding and mating that part, one at a time? Example 10 rods inserted into 10 holes of a plate. Nvrmind figured it out "Brice Wu" <brice@kostklip.com> wrote in message news:mcuod.309564$nl.145312@pd7tw3no... > Anyone know how i can insert the same part into holes that are linear > patterened, without adding and mating that part, one at a time? Example 10 > rods inserted into 10 holes of a plate. > > I suppose you have a hole (cut) feature and a linear pattern feature in...

Bulk copy or bulk move
I need to port a large number of files from one directory to another, what is the simplest command or commands to accomplish this. On Monday 16 July 2012 17:45, divergent.tseries@gmail.com conveyed the following to comp.unix.shell... > I need to port a large number of files from one directory to another, > what is the simplest command or commands to accomplish this. (cd /source/dir && tar cf - .) | (cd /destination/dir && tar xvpf -) -- = Aragorn = (registered GNU/Linux user #223157) divergent.tseries@gmail.com writes: > I need to port a large n...

Insert question #2 1458502
I set up a database of civic league members and residences. I set the primary key to conform to addresses by street numbers. Unfortunately, I omitted two buildings. How do I insert the data for these two items where they should be ? The Primary Key doesn't seem to like that :( Thanks much, newbie here "ams" <none@cox.net> wrote in message news:m2Lqc.31352$Md.29945@lakeread05... > I set up a database of civic league members and residences. > I set the primary key to conform to addresses by street numbers. > Unfortunately, I omitted two buildings. > How do I ...

Stored procedure where clause
I have an existing query from MS Access that I want to convert it to SQL Server Stored Proc. My problem is on how to convert the WHERE clause. This is the query from MS Access: SELECT SchYrSemCourseJoin.SchYrSemCourseID, Students.IDNo, [LastName] & ", " & [FirstName] & " " & [MiddleName] AS Name, Program.ProgramTitle, Program.ProgramDesc, SchYrSem.SchYr, SchYrSem.Sem, SchYrSem.Year, SchYrSem.Section AS Section1, Major.Major, Course.CourseCode, Course.CourseTitle, Course.Unit, SchYrSemCourseJoin.Final, SchYrSem.SchYrSemID FROM (Program INNER JOIN Students O...

Inks in Bulk
Does anyone know of a supplier who provides quality inks in bulk for Epson desktop printers? I'm not one to mess around refilling cartridges & Epson doesn't offer its inks in bulk.Yeah, I know Epson doesn't do it because of the money. Is their hype re: quality of their inks so true that bulk ink suppliers can't meet the quality of Epson cartridge inks? Free enterprise is great, if, IF the same quality can be achieved at a lesser price. One4All wrote: >Does anyone know of a supplier who provides quality inks in bulk for >Epson desktop printers? >...

Re: inserting values into macro variable using array #4
Helen, Without a macro, data h / view = h ; merge ab11 (where = (ab11 > 1)) ab12 (where = (ab12 > 1)) ab13 (where = (ab13 > 1)) ; run ; proc freq data = h ; tables ab11 ab12 ab13 ; run ; Just disregard missing values count after each output table. OK, now you may say it is not dynamic enough - I have to type each variable name thrice. It would be a valid point. But you still need no macro to make SAS assemble the code for you: data cntl ; input name $ @@ ; cards ; ab11 ab12 ab13 run ; proc sql noprint ; select cats (name, '(where=(', nam...

Store Array to Access w/o Parsing Each Row
Hello all, Is there anyway to store an array to MS Access 2002 without parsing the entire array row-by-row. For example, Oracle allows you to store BLOBs (binary large objects). I would like to be able to say in VB/VBA With rstName .AddNew !fieldName = ArrayName .Update .Close End With Any ideas? Thanks!! Trip -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 According to strict SQL design principles you shouldn't have more than one item per cell (IOW, each array element should be in a separate column). But, if you insist.... Use the Split() function to break out ea...