Use sequences (Forms and PL / SQL)

Dicas do Oracle Forms Builder - Blocos, Itens, LOV, Canvas, Triggers, comandos, PLL, d2kwutil, FMB, Alert, menus, etc
Post Reply
Goro
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 4
Joined: Wed, 17 Dec 2014 3:26 pm

Good morning friends!
I'm a beginner in development (beginner even), so it may be that I take a little more time or need more examples to understand, anyway, I'm setting up a system, and I came across a situation I saw many examples , but not practical, and I'm killing myself here, next ...
I have a table (t_mermer) with the CD_Porner columns (code) and DS_Porner (description), I created an application for this table, when starting a registration of vendor, the operator must enter the description of it and the CD_Porner should take the next sequence number, could you help me?
Renato Menezes Viana
Rank: Analista Pleno
Rank: Analista Pleno
Posts: 128
Joined: Sat, 18 Nov 2006 11:51 am
Location: Rio de Janeiro - RJ

Goro: Do ??not forget to search, the most important activity in the IT or any other technological.

Staying around just asking will not get much.

When finished, make a summary well done the way you'd like it.

Link:
http://www.oracle.com/technetwork/pt/ar ... 1-ptb.html
ABS,
Renato Viana
Goro
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 4
Joined: Wed, 17 Dec 2014 3:26 pm

Goro: Do ??not forget to search, the most important activity in the IT or any other technological.

Staying around just asking will not get much.

When finished, make a summary well done the way you would like.
Link: Thank you Renato!
But seriously, he did not help me a lot, I will not be discouraged, not "I'm just asking", I believe you did not understand, maybe I'll be mistaken for me, I do not think you'vê read the link you passed, I read (long before I opened post), and I could not, because to set up the sequence, it was very clear, very simple, but I could not explain for example how to run a function that would seek the next value of Sequence, do the insert By the bank, quiet ... But how to do this by application?

Big hug, and do not worry, I will continue searching, thanks!
Renato Menezes Viana
Rank: Analista Pleno
Rank: Analista Pleno
Posts: 128
Joined: Sat, 18 Nov 2006 11:51 am
Location: Rio de Janeiro - RJ

Goro: I read, now did you read it?

Select all

 
select seq_decrescente_5.nextval from dual;
... How to create a number v_seq_next

Select all

select seq_decrescente_5.nextval into v_seq_next from dual;
Goro
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 4
Joined: Wed, 17 Dec 2014 3:26 pm

Dude, I liked you ... kkkkkk .... I'll learn, I'm sure ... Thank you so much for having patience with me and teach me ... Ditches there!

Liki ... I'm sure I'm doing it wrong, or understood, wrong, but I read, look just I created a trigger (key-next-item) in the forms, then what I'm thinking is to return on the block. CAMPO, NEXTVAL .... PERAE ... would that be?

Select all

DECLARE  
	V_SEQ_NEXT NUMBER; 
begin 
	select seq_PRODUTO.nextval into v_seq_next from dual; 
	:T_FORNECEDOR.CD_FORNECEDOR := V_SEQ_NEXT; 
end;
I will try !!
Goro
Rank: Estagiário Pleno
Rank: Estagiário Pleno
Posts: 4
Joined: Wed, 17 Dec 2014 3:26 pm

Guy!!!
I got it !!! Thanks Renato !! Thank you very much! I'll be upgrading here ... but thank you !!!!

abs; : D
Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 11 guests