473,395 Members | 1,368 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

UDB V8.2 : Append value to a column while loading using Method L

Hi,

I have a input file in the following format ,

1-4 5-8 9-10 11 12-14
------------------------------------
1000 +500 25 1 250
2000 -520 55 1 25
2500 *525 55 1 125

I want to append position 5 and 11 and load into a column(ex. in the
previous case apppending position 5 and 11 we get "+1" and "-1" for the
two corresponding rows. Is this possible in UDB ?

If the above is possible, is it possible to append a value say "x" to
position 5, while loading. the result in this case would be "+x", "-x"
and "*x"

Note: The input file/pipe shouldn't be changed. In substance, I want to
generate the value based on two fileds that are not close together in
the input file. If that option is not available, I want to append a
known value/constant to the value in position say 5 and load the
resultant vale into the table.

Thanks.
GS-

Sep 5 '06 #1
1 1554
Search for "generated column udb db2" and see what you get.

Assuming you're loading 5-8 and 11 into columns anyway, you could
define your generated column as sign([5-8]) * [11]

Of course, you might then say you don't want the rest of 5-8 and 11 in
your target table. But I guess you can stick it into a staging table
and then insert the results of that into the final target table. (Or
use LOAD FROM CURSOR, which I guess could give better performance than
an INSERT...)

Hope that helps.

Sep 6 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Larry Rekow | last post by:
In Access I have a macro that, each night, takes a table with a primary key defined in it, and deletes all the rows. Then it imports/appends records from a fixed width text file. In this way,...
8
by: Lyn | last post by:
Hi, Can anyone tell me how the initial value displayed in Combo Box is determined when a form is opened? I am loading the dropdown from one field ("CategoryName") of a table, with "ORDER BY ". ...
6
by: allyn44 | last post by:
Hi---I have to import some data from excel into an Access table--the code below is working ok but I would like to condense it by running a loop. The number of records can vary from 1 to 30 in each...
3
by: ethoemmes | last post by:
I have used the import class module from http://www.mvps.org/access/modules/mdl0057.htm. This reads my text file into a string called myString. I am trying to append this string into table...
2
by: Ray Holtz | last post by:
I have a form that shows a single record based on a query criteria. When I click a button it is set to use an append query to copy that record to a separate table, then deletes the record from the...
3
by: barry | last post by:
I have the following: function(NAMED) { sString.Append("document.forms.NAMED.style.visibility = 'hidden'") } and would like to convert the NAMED into the object it represents - for example in...
1
by: aj | last post by:
DB2 WSUE LUW v8.2 FP4 (aka v8.1 FP11) RHEL AS 4 I am EXPORTing in IXF format from one schema and then LOADing into another schema. The DB modeling tool I am using likes to put the PK columns...
3
by: =?ISO-8859-2?Q?Gregor_Kova=E8?= | last post by:
Hi! Is it possible to change a value of a column in IMPORT command. Something like: IMPORT FROM TABLE1.IXF OF IXF METHOD N (TAB_NAME, TAB_DATE) INSERT INTO TMP_TABLE1(TAB_NAME, CURRENT DATE -...
42
by: Armin | last post by:
Hi, just a dumb question. Let a = Why is the value of a.append(7) equal None and not ?? --Armin
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.