Em Andamento

PL/SQL query to update field

Hi I want a PL/SQL query for ORacle 10g to update a field utilizing the logic Below.

A table has the following 4 fields (non- Indexed)

REQUEST_NUMBER NUMBER(8)

ORDER_NUMBER NUMBER(8)

ORDER_VERSION NUMBER(8)

CURRENT_INDICATOR BOOLEAN

The REQUEST_NUMBER plus ORDER_NUMBER form a unique key and can have various ORDER_VERSION. versions that grow incrementally from 1,2,3 and so on.

When a new version comes up the old one is made "non-current". I already have the data in the table, I want to update the CURRENT_INDICATOR to YES/NO based on the ORDER_VERSION:

LOGIC : For every REQUEST_NUMBER + ORDER_NUMBER the greatest ORDER_VERSION is the CURRENT_INDICATOR = TRUE

rest of the versions are CURRENT_INDICATOR = FALSE

Thanks US

Habilidades: Instalação de Script, Shell Script, Arquitetura de software

Ver mais: sql to oracle, sql oracle pl sql, sql in pl sql, pl sql software, pl sql in oracle, pl sql and oracle, pl sql and, oracle sql pl, for in pl sql, for i in oracle pl sql, pl sql oracle, oracle sql number, in pl sql, update old, SQL Query, SQL PL SQL , query table, pl\sql, pl/sql, pl-sql, oracle:pl, oracle pl/sql, oracle pl, oracle install, data query

Acerca do Empregador:
( 67 comentários ) Australia

ID do Projeto: #3036139

Premiar a:

sinharavi

See private message.

$7 USD em 1 dia
(71 Avaliações)
5.8

2 freelancers estão ofertando em média $8 para este trabalho

ctgr

See private message.

$8.5 USD em 1 dia
(13 Comentários)
3.1