![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi all, It is any function in Oracle 9i equal o with a similar funtionability than (i=i+1). I want to do a "Insert Into a select" but one fileds is a counter ... Thanks in advance .. A. |
#3
| |||
| |||
|
|
On May 27, 2:15 pm, valigula <valig... (AT) gmail (DOT) com> wrote: Hi all, It is any function in Oracle 9i equal o with a similar funtionability than (i=i+1). I want to do a "Insert Into a select" but one fileds is a counter ... Thanks in advance .. A. I am not very clear on the question, but I guess you can use ROWNUM, a sequence or implement your own function. Maybe others have more ideas. |
#4
| |||
| |||
|
|
On 27 mayo, 20:50, Valentin Minzatu <valentinminz... (AT) yahoo (DOT) com> wrote: On May 27, 2:15 pm, valigula <valig... (AT) gmail (DOT) com> wrote: Hi all, It is any function in Oracle 9i equal o with a similar funtionability than (i=i+1). I want to do a "Insert Into a select" but one fileds is a counter ... Thanks in advance .. A. I am not very clear on the question, but I guess you can use ROWNUM, a sequence or implement your own function. Maybe others have more ideas. Thanks for your respond i have a function that already does it. But it is to resource/time consuming, therefore i am trying to do it on the fly. And i can not use the rownum since i will need to start from the value 53425...this number should be increase by one in every row insert. A. |
#5
| |||
| |||
|
|
On May 27, 11:44 pm, valigula <valig... (AT) gmail (DOT) com> wrote: On 27 mayo, 20:50, Valentin Minzatu <valentinminz... (AT) yahoo (DOT) com> wrote: On May 27, 2:15 pm, valigula <valig... (AT) gmail (DOT) com> wrote: Hi all, It is any function in Oracle 9i equal o with a similar funtionability than (i=i+1). I want to do a "Insert Into a select" but one fileds is a counter ... Thanks in advance .. A. I am not very clear on the question, but I guess you can use ROWNUM, a sequence or implement your own function. Maybe others have more ideas. Thanks for your respond i have a function that already does it. But it is to resource/time consuming, therefore i am trying to do it on the fly. And i can not use the rownum since i will need to start from the value 53425...this number should be increase by one in every row insert. A. Research SEQUENCEs and BEFORE INSERT FOR EACH ROW triggers. Oracle doesn't support 'identity'/autoincrement columns. Hth, Vladimir M. Zakharychev N-Networks, makers of Dynamic PSP(tm) http://www.dynamicpsp.com |
#6
| |||
| |||
|
|
On 27 mei, 22:06, "Vladimir M. Zakharychev" vladimir.zakharyc... (AT) gmail (DOT) com> wrote: On May 27, 11:44 pm, valigula <valig... (AT) gmail (DOT) com> wrote: On 27 mayo, 20:50, Valentin Minzatu <valentinminz... (AT) yahoo (DOT) com> wrote: On May 27, 2:15 pm, valigula <valig... (AT) gmail (DOT) com> wrote: Hi all, It is any function in Oracle 9i equal o with a similar funtionability than (i=i+1). I want to do a "Insert Into a select" but one fileds is a counter ... Thanks in advance .. A. I am not very clear on the question, but I guess you can use ROWNUM, a sequence or implement your own function. Maybe others have more ideas. Thanks for your respond i have a function that already does it. But it is to resource/time consuming, therefore i am trying to do it on the fly. And i can not use the rownum since i will need to start from the value 53425...this number should be increase by one in every row insert. A. Research SEQUENCEs and BEFORE INSERT FOR EACH ROW triggers. Oracle doesn't support 'identity'/autoincrement columns. Hth, Vladimir M. Zakharychev N-Networks, makers of Dynamic PSP(tm) http://www.dynamicpsp.com insert into tbl2 select rownum+53424, fielda,fieldb from tbl2 |
![]() |
| Thread Tools | |
| Display Modes | |
| |