Nummernkreise » Historie » Version 11
[X] Daniel S, 09.01.2020 11:03
1 | 1 | [X] Daniel S | h1. Nummernkreise |
---|---|---|---|
2 | |||
3 | h2. Einstellen der Dokumentnummern |
||
4 | |||
5 | 7 | [X] Daniel S | > Hinweis: diese Bsp sind für Jahr "2020" - Nummer nach 24/25/26 |
6 | 6 | [X] Daniel S | |
7 | 9 | [X] Daniel S | <pre><code class="sql"> |
8 | 8 | [X] Daniel S | SELECT setval('auftg_ag_dokunr_seq', 25*20*0000); -- Angebot/Auftragsnummer |
9 | SELECT setval('ldsdok_ld_dokunr_seq', 24*20*0000); -- Bestellung |
||
10 | SELECT setval('auswlog_aw_dokunr_seq', 26*20*0000); -- Auswärts |
||
11 | 9 | [X] Daniel S | </code></pre> |
12 | 1 | [X] Daniel S | |
13 | h2. Umstellen auf neue Nummernkreise |
||
14 | |||
15 | 10 | [X] Daniel S | > Hinweis: aktuelle Quellen prüfen, falls sich an Maskierung, Benamung usw. etwas geändert hat im SQL Script! |
16 | 1 | [X] Daniel S | |
17 | 4 | [X] Daniel S | h2. Einkauf |
18 | |||
19 | h3. Anfrage an Lieferant |
||
20 | |||
21 | <pre><code class="sql"> |
||
22 | UPDATE TSystem.numcircles SET nc_ident='#old.'||nc_ident, nc_active = FALSE WHERE nc_ident = 'anfrage'; |
||
23 | |||
24 | INSERT INTO TSystem.numcircles (nc_ident, nc_description, nc_preselect, nc_num, nc_modulname, nc_checksql) |
||
25 | 5 | [X] Daniel S | VALUES ('anfrage', 'Anfrage Lieferant', '''ANFL'' || to_char(current_date, ''YY'') || ''-'' || lpad(NC_NUM, 5, 0)', 100, 'TFormAnfrage', |
26 | 4 | [X] Daniel S | 'SELECT true FROM anfrage WHERE anf_nr = :mynewchecknumber'); |
27 | </code></pre> |
||
28 | |||
29 | h2. Verkauf |
||
30 | |||
31 | h3. Anfrage von Kunde |
||
32 | 1 | [X] Daniel S | |
33 | <pre><code class="sql"> |
||
34 | 3 | [X] Daniel S | UPDATE TSystem.numcircles SET nc_ident='#old.'||nc_ident, nc_active = FALSE WHERE nc_ident = 'kanfrage'; |
35 | 1 | [X] Daniel S | |
36 | INSERT INTO TSystem.numcircles (nc_ident, nc_description, nc_preselect, nc_num, nc_modulname, nc_checksql) |
||
37 | 11 | [X] Daniel S | VALUES ('kanfrage', 'Anfrage von Kunde', '''ANFK'' || to_char(current_date, ''YY'') || ''-'' || lpad(NC_NUM, 5, 0)', 100, 'TFormKundenAnfrage', |
38 | 1 | [X] Daniel S | 'SELECT true FROM kundanfrage WHERE kanf_nr = :mynewchecknumber'); |
39 | </code></pre> |
||
40 | |||
41 | h3. Angebot |
||
42 | |||
43 | <pre><code class="sql"> |
||
44 | 3 | [X] Daniel S | UPDATE TSystem.numcircles SET nc_ident='#old.'||nc_ident, nc_active = FALSE WHERE nc_ident = 'aauftg'; |
45 | |||
46 | 1 | [X] Daniel S | INSERT INTO TSystem.numcircles (nc_ident, nc_description, nc_preselect, nc_num, nc_modulname, nc_checksql) |
47 | 5 | [X] Daniel S | VALUES ('aauftg', 'Angebote', '''AN'' || to_char(current_date, ''YY'') || ''-'' || lpad(NC_NUM, TSystem.Settings__GetInteger(''auftg__ag_nr__numlength'', 5), 0)', 100, 'TFormAuftg', |
48 | 1 | [X] Daniel S | 'SELECT true FROM auftg WHERE ag_astat = ''A'' AND ((ag_nr = :mynewchecknumber) OR (ag_nr = (:mynewchecknumber || ''.QS'')))'); |
49 | |||
50 | </code></pre> |
||
51 | |||
52 | h3. Auftragsbestätigung |
||
53 | |||
54 | <pre><code class="sql"> |
||
55 | 3 | [X] Daniel S | UPDATE TSystem.numcircles SET nc_ident='#old.'||nc_ident, nc_active = FALSE WHERE nc_ident = 'eauftg'; |
56 | 1 | [X] Daniel S | |
57 | INSERT INTO TSystem.numcircles (nc_ident, nc_description, nc_preselect, nc_num, nc_modulname, nc_checksql) |
||
58 | 5 | [X] Daniel S | VALUES ('eauftg', 'Kundenaufträge', '''AG'' || to_char(current_date, ''YY'') || ''-'' || lpad(NC_NUM, 5, 0)', 100, 'TFormAuftg', |
59 | 1 | [X] Daniel S | 'SELECT true FROM auftg WHERE ag_astat = ''E'' AND ((ag_nr = :mynewchecknumber) OR (ag_nr = (:mynewchecknumber || ''.QS'')))'); |
60 | |||
61 | 3 | [X] Daniel S | UPDATE TSystem.numcircles SET nc_ident='#old.'||nc_ident, nc_active = FALSE WHERE nc_ident = 'rauftg'; |
62 | 2 | [X] Daniel S | |
63 | 1 | [X] Daniel S | INSERT INTO TSystem.numcircles (nc_ident, nc_description, nc_preselect, nc_num, nc_modulname, nc_checksql) |
64 | 5 | [X] Daniel S | VALUES ('rauftg', 'Rahmenaufträge', '''RA'' || to_char(current_date, ''YY'') || ''-'' || lpad(NC_NUM, 5, 0)', 100, 'TFormAuftg', |
65 | 1 | [X] Daniel S | 'SELECT true FROM auftg WHERE ag_astat = ''R'' AND (ag_nr = :mynewchecknumber)'); |
66 | </code></pre> |