473,395 Members | 1,571 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.

How update one row with timestamp diferent

Thanks to answer topic previous!!!!

I use this script to update one table

MERGE INTO EIS.CLI_HISTORY TXN
USING EIS.CLI_MAPING CLI
ON TXN.CLIENTID = CLI.CLIENTID
WHEN MATCHED AND
CLI.STATUSID = 3
AND CLI.CLIENTID != CLI.MAPPEDCLIENTID AND
CLI.CLIENTID = 24180 THEN
UPDATE
SET TXN.ISMERGED = 2,
TIMEACTUAL = CURRENT TIMESTAMP,
TXN.CLIENTID = CLI.MAPPEDCLIENTID;

But show problems of duplicate and the problem is with of row
TIMEACTUAL, because I don't put this row and the update was successful.

How I can update one row with TIMESTAMP but that is different. For
example

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.05

But I need that is diferent like this

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.06
Thanks to all !!!

Iván

Aug 25 '06 #1
3 6810
Hi, Ivan.

My apologies, but I'm afraid I don't understand what you're trying to
do and what problem(s) you're encountering. Can you take another crack
at describing the task at hand? I'm sure a solution exists, we just
need to nail down the requirements a bit.

Regards,

--Jeff

Ivan wrote:
Thanks to answer topic previous!!!!

I use this script to update one table

MERGE INTO EIS.CLI_HISTORY TXN
USING EIS.CLI_MAPING CLI
ON TXN.CLIENTID = CLI.CLIENTID
WHEN MATCHED AND
CLI.STATUSID = 3
AND CLI.CLIENTID != CLI.MAPPEDCLIENTID AND
CLI.CLIENTID = 24180 THEN
UPDATE
SET TXN.ISMERGED = 2,
TIMEACTUAL = CURRENT TIMESTAMP,
TXN.CLIENTID = CLI.MAPPEDCLIENTID;

But show problems of duplicate and the problem is with of row
TIMEACTUAL, because I don't put this row and the update was successful.

How I can update one row with TIMESTAMP but that is different. For
example

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.05

But I need that is diferent like this

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.06
Thanks to all !!!

Iván
Aug 25 '06 #2
Thanks!!!

I need update more of one row with Timestamp, for example mi script
extract 4 rows, and I need update these rows with diferent timestamp

Row1 TimeActual 2005-12-09-09.31.52
Row1 TimeActual 2005-12-09-09.31.53
Row1 TimeActual 2005-12-09-09.31.54
Row1 TimeActual 2005-12-09-09.31.55

I need that each row is different to be able to update my the table.

Hope is more clear.

Greetings
Iván

jefftyzzer wrote:
Hi, Ivan.

My apologies, but I'm afraid I don't understand what you're trying to
do and what problem(s) you're encountering. Can you take another crack
at describing the task at hand? I'm sure a solution exists, we just
need to nail down the requirements a bit.

Regards,

--Jeff

Ivan wrote:
Thanks to answer topic previous!!!!

I use this script to update one table

MERGE INTO EIS.CLI_HISTORY TXN
USING EIS.CLI_MAPING CLI
ON TXN.CLIENTID = CLI.CLIENTID
WHEN MATCHED AND
CLI.STATUSID = 3
AND CLI.CLIENTID != CLI.MAPPEDCLIENTID AND
CLI.CLIENTID = 24180 THEN
UPDATE
SET TXN.ISMERGED = 2,
TIMEACTUAL = CURRENT TIMESTAMP,
TXN.CLIENTID = CLI.MAPPEDCLIENTID;

But show problems of duplicate and the problem is with of row
TIMEACTUAL, because I don't put this row and the update was successful.

How I can update one row with TIMESTAMP but that is different. For
example

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.05

But I need that is diferent like this

TimeActual 2005-12-09-09.31.05
TimeActual 2005-12-09-09.31.06


Thanks to all !!!

Iván
Aug 28 '06 #3
Use TIMESTAMP(generate_unique())
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

IOD Conference
http://www.ibm.com/software/data/ond...ness/conf2006/
Aug 28 '06 #4

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

Similar topics

2
by: Harald Servat Gelabert | last post by:
Dear news-team I'm using MySQL 4.0.15a (with PHP 4.3.4rc1 and Apache 2.0.47 under FreeBSD). I'm having problems when updating a column of a table (it updates an extra column). As an...
7
by: kaming | last post by:
Dear all, I found that I can't update or delete a DB2 record with timestamp using Access through ODBC. The Access complains "No current record" while I attempt to update or delete the record...
3
by: Mihaly | last post by:
I want to update a record into a table in SQL Server 2000 database from C#. This table is used concurently for other users too, and I want to be sure that from the read of record to the update no...
9
by: Mahesh S | last post by:
Hi I have to perform an update on a table. I am having problems figuring out how to join two tables as I need to check a value in a different table before performing the update. I have two...
5
by: wpellett | last post by:
I can not get the SQL compiler to rewrite my SQL UPDATE statement to include columns being SET in a Stored Procedure being called from a BEFORE UPDATE trigger. Example: create table...
1
by: bughunter | last post by:
simple query select * from "Result" res where (res."QID" = 51541 or res."QID" = 51542) works fine ("SRV-BL"."Result" ~ 900000 rows) and returns 36 rows but update - no! update...
2
by: mokazawa1 | last post by:
Hi, I'm using stored procedures in DB2 UDB 8.1.2. In this stored, I execute a select for update command, opening a cursor. Then I update the rows using fetch and current of. The problem is that...
13
by: dennis | last post by:
Hello, I'm having trouble solving the following problem with DB2 UDB 8.2. I need to create a trigger that performs certain extra constraint validations (temporal uniqueness). One of the tables...
3
by: Michel Esber | last post by:
Hi all, DB2 V8 LUW FP 15 There is a table T (ID varchar (24), ABC timestamp). ID is PK. Our application needs to frequently update T with a new value for ABC. update T set ABC=? where ID...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
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.