Presentasi sedang didownload. Silahkan tunggu

Presentasi sedang didownload. Silahkan tunggu

Materi 13-14 Algoritma Umum untuk Masalah Bisnis Disusun Oleh : Yulyani Arifin,S.Kom, MMSI.

Presentasi serupa


Presentasi berjudul: "Materi 13-14 Algoritma Umum untuk Masalah Bisnis Disusun Oleh : Yulyani Arifin,S.Kom, MMSI."— Transcript presentasi:

1 Materi Algoritma Umum untuk Masalah Bisnis Disusun Oleh : Yulyani Arifin,S.Kom, MMSI

2 Agenda Struktur Program Laporan Dengan Page Break Single Level Control Break Multiple Level Control Break Sequential File Update

3 Mahasiswa mampu menyelesaikan permasalahan bisnis dengan algoritma laporan Page break, Single Level Break, Multiple Level Break dan Sequential File Update Kemampuan Akhir yang Diharapkan

4 MATERI BELAJAR Struktur Program Pada umumnya algoritma terdiri dari 1 modul utama dan 3 sub modul yaitu : Modul inisial proses, sebelum loop Modul proses dalam loop Modul final proses, sesudah loop

5 MATERI BELAJAR Struktur Program Pada umumnya algoritma terdiri dari 1 modul utama dan 3 sub modul yaitu : Modul inisial proses, sebelum loop Modul proses dalam loop Modul final proses, sesudah loop

6 MATERI BELAJAR Struktur Program Hierarchy Chart seperti di bawah ini :

7 MATERI BELAJAR Struktur Program Modul Utama seperti di bawah ini : Proses_sequential_File Perform_initial_processing Read First Record DOWHILE more records exist Process_this_record Read next record ENDDO Perform_Final_Processing END

8 MATERI BELAJAR Laporan Page Break Umumnya Laporan membutuhkan : Page Heading Lines Coloum Heading Lines Detail Lines Total Lines Halaman berikut sesudah mencapai maksimum baris

9 MATERI BELAJAR Laporan Page Break Contoh Laporan Page Break

10 MATERI BELAJAR Laporan Page Break Hierarchy Chart = New Module

11 MATERI BELAJAR Laporan Page Break B. Algoritma Solusi Mainline : Print_report_program Initialise_variable_fields Print_page_headings Read first record DOWHILE more records exist IF linecount>max_detail_lines THEN Print_page_headings ENDIF Process_this_record Read next record ENDDO Print_report_totals END

12 MATERI BELAJAR Laporan Page Break B. Algoritma Solusi Sub Modul 1.Initialise_variable_fields set accumulators to zero set pagecount to zero set linecount to zero set max_detail_lines to required value END 2. Print_page_headings increment pagecount print main heading lines print column heading lines print blank line(if required) set linecount to zero END

13 MATERI BELAJAR Laporan Page Break B. Algoritma Solusi Sub Modul 3. Process_this_record perform necessary calculations (if any) Print_detail_line Accumulate_total_fields END 4. Print_detail_line Print detail line increment linecount END 5. Accumulate_total_fields increment accumulators as required END 6. Print_report_totals Print total line(s) END

14 MATERI BELAJAR Laporan Single Level Control Break Control break total lines adalah ringkasan baris untuk sekelompok record yang terdiri dari record key yang sama. Control Field digunakan untuk identifikasi sebuah record atau sekelompok record dalam file. Control break terjadi setiap kali ada perubahan nilai di control field. Control break total line akan dicetak setiap kali control break terdeteksi.

15 MATERI BELAJAR Laporan Single Level Control Break Contoh Laporan Single Level Control Break

16 MATERI BELAJAR Laporan Single Level Control Break Ada dua hal yang perlu diperhatikan : File harus terurut berdasarkan urutan control field Harus membandingkan control field yang sekarang dengan control field sebelumnya.

17 MATERI BELAJAR Laporan Single Level Control Break A. Hierarchy Chart

18 MATERI BELAJAR Laporan Single Level Control Break Semua laporan control break akan membutuhkan variabel : Variabel this_control_field Variabel prev_control_field Satu atau lebih variabel untuk akumulasi total control break Satu atau lebih variabel untuk akumulasi total laporan.

19 MATERI BELAJAR Laporan Single Level Control Break B. Algoritma solusi Produce_single_level_control_break Initialise_variable_fields Print_page_headings read first record this_control_field = control field prev_control_field = control field DOWHILE more records exist IF this_control_field NOT= prev_control_field THEN Print_control_total_line prev_control_field = this_control_field ENDIF Produce_single_level_control_break Initialise_variable_fields Print_page_headings read first record this_control_field = control field prev_control_field = control field DOWHILE more records exist IF this_control_field NOT= prev_control_field THEN Print_control_total_line prev_control_field = this_control_field ENDIF IF linecount > max_detail_lines THEN Print_page_headings ENDIF Process_this_record read next record this_control_field = control field ENDDO Print_control_total_line Print_report_totals END IF linecount > max_detail_lines THEN Print_page_headings ENDIF Process_this_record read next record this_control_field = control field ENDDO Print_control_total_line Print_report_totals END

20 MATERI BELAJAR Laporan Single Level Control Break Sub Modul 1.Initialise_variable_fields set control total accumulators to zero set report total accumulators to zero set pagecount to zero set linecount to zero set max_detail_lines to required value END 1.Initialise_variable_fields set control total accumulators to zero set report total accumulators to zero set pagecount to zero set linecount to zero set max_detail_lines to required value END 2 Print_page_headings Increment pagecount print main heading lines print column heading lines print blank line (if required) set linecount to zero END 2 Print_page_headings Increment pagecount print main heading lines print column heading lines print blank line (if required) set linecount to zero END 3. Process_this_record perform necessary calculations (if any) Print_detail_line Accumulate_control_line END 3. Process_this_record perform necessary calculations (if any) Print_detail_line Accumulate_control_line END 4. Print_control_total_line print control total line print blank line (if required) increment linecount Reset_control_totals END 4. Print_control_total_line print control total line print blank line (if required) increment linecount Reset_control_totals END

21 MATERI BELAJAR Laporan Single Level Control Break Sub Modul 5 Print_report_totals print report total line END 5 Print_report_totals print report total line END 6. Print_detail_line Print_detail_line increment linecount END 6. Print_detail_line Print_detail_line increment linecount END 7. Accumulate_control increment control total accumulators END 7. Accumulate_control increment control total accumulators END 8. Reset_control_totals add control total accumulators to report total accumulators set control total accumulators to zero END 8. Reset_control_totals add control total accumulators to report total accumulators set control total accumulators to zero END

22 MATERI BELAJAR Laporan Multi Level Control Break Contoh Laporan Multi Level Control Break

23 MATERI BELAJAR Laporan Multi Level Control Break Konsep yang diterapkan di Single Level Control Break juga sama diterapkan di Multi Level Control Break : File harus diurut berdasarkan control field. Setiap record yang dibaca harus dibandingkan control field ( mayor dan minor) dengan control field sebelumnya.

24 MATERI BELAJAR Laporan Multi Level Control Break A. Hierarchy Chart

25 MATERI BELAJAR Laporan Multi Level Control Break B. Algoritma Solusi ( Mainline) Produce_multiple_level_control_break Initialise_variable_fields Print_page_headings read first record this_minor_control_field = minor control field prev_minor_control_field = minor control field this_major_control_field = major control field prev_major_control_field = major control field

26 MATERI BELAJAR Laporan Multi Level Control Break B. Algoritma Solusi ( Mainline) DOWHILE more record exist IF this_major_control_field NOT= prev_major_control_field THEN Print_minor_control_totals prev_minor_control_field = this_minor_control_field Print_major_control_totals prev_major_control_field = this_major_control_field ELSE IF this_minor_control_field NOT=prev_minor_control_field THEN Print_minor_control_totals prev_minor_control_field = this_minor_control_field ENDIF

27 MATERI BELAJAR Laporan Multi Level Control Break B. Algoritma Solusi (Mainline) IF linecount>max_detail_lines THEN Print_page_heading ENDIF Process_this_record read next record this_minor_control_field = minor control field this_major_control_field= major control field ENDDO print_minor_control_totals print_major_control_totals print_report_totals END

28 MATERI BELAJAR Laporan Single Level Control Break Sub Modul 1. initialise_variable_fields set minor control total accumulators to zero set major control total accumulators to zero set pagecount to zero set linecount to zero set max_detail_lines to required value END 1. initialise_variable_fields set minor control total accumulators to zero set major control total accumulators to zero set pagecount to zero set linecount to zero set max_detail_lines to required value END 2Print_page_headings increment pagecount print main heading lines print column heading lines print blank line (if required) set linecount to zero END 2Print_page_headings increment pagecount print main heading lines print column heading lines print blank line (if required) set linecount to zero END 3. Process_this record perform necessary calculation (if any) print_detail_line accumulate_control_totals END 3. Process_this record perform necessary calculation (if any) print_detail_line accumulate_control_totals END 4. Print_minor_control_totals print minor control total line print blank line (if required) increment linecount Reset_minor_control_totals END 4. Print_minor_control_totals print minor control total line print blank line (if required) increment linecount Reset_minor_control_totals END

29 MATERI BELAJAR Laporan Single Level Control Break Sub Modul 5. Print_major_control_totals print major control total line print blank line (if required) increment linecount Reset_major_control_totals END 5. Print_major_control_totals print major control total line print blank line (if required) increment linecount Reset_major_control_totals END 6. Print_report_totals print report total line END 6. Print_report_totals print report total line END 7. Print_Detail_line print detail line increment linecount END 7. Print_Detail_line print detail line increment linecount END 8. Accumulate_control_totals increment minor control total accumulators END 8. Accumulate_control_totals increment minor control total accumulators END

30 MATERI BELAJAR Laporan Single Level Control Break Sub Modul 9Reset_minor_control_totals add minor control total accumulators to major control total accumulators set minor control total accumulators to zero END 9Reset_minor_control_totals add minor control total accumulators to major control total accumulators set minor control total accumulators to zero END 10Reset_major_control_totals add major control total accumulators to report total accumulators set major control total accumulators to zero END 10Reset_major_control_totals add major control total accumulators to report total accumulators set major control total accumulators to zero END

31 MATERI BELAJAR Sequential File Update Update file secara sequential umum untuk aplikasi batch prosesing. Berikut flow chart program update sequential :

32 MATERI BELAJAR Sequential File Update Konsep Sistem : File Master : File terdiri dari informasi permanen dan semi permanen. Record berurutan berdasarkan key field. Contoh : master pelanggan File Transaksi : Terdiri dari semua data dan aktivitas yang termasuk dalam file master.

33 MATERI BELAJAR Sequential File Update Tiga tipe transaksi update : Tambah record baru Update atau ubah record lama Delete record lama Laporan Audit List detil semua transaksi yang diterapkan pada file master Tujuannya untuk kontrol. Laporan Error List detil error yang terjadi sepanjang proses update.

34 MATERI BELAJAR Q & A


Download ppt "Materi 13-14 Algoritma Umum untuk Masalah Bisnis Disusun Oleh : Yulyani Arifin,S.Kom, MMSI."

Presentasi serupa


Iklan oleh Google