KR20010105679A - Csv report generation - Google Patents

Csv report generation Download PDF

Info

Publication number
KR20010105679A
KR20010105679A KR1020000026385A KR20000026385A KR20010105679A KR 20010105679 A KR20010105679 A KR 20010105679A KR 1020000026385 A KR1020000026385 A KR 1020000026385A KR 20000026385 A KR20000026385 A KR 20000026385A KR 20010105679 A KR20010105679 A KR 20010105679A
Authority
KR
South Korea
Prior art keywords
sql
user
csv
film
name
Prior art date
Application number
KR1020000026385A
Other languages
Korean (ko)
Other versions
KR100368913B1 (en
Inventor
김지섭
Original Assignee
김지섭
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 김지섭 filed Critical 김지섭
Priority to KR10-2000-0026385A priority Critical patent/KR100368913B1/en
Publication of KR20010105679A publication Critical patent/KR20010105679A/en
Application granted granted Critical
Publication of KR100368913B1 publication Critical patent/KR100368913B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/12Use of codes for handling textual entities
    • G06F40/151Transformation
    • G06F40/157Transformation using dictionaries or tables

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A rolling bearing is used for supporting a rocking mechanism or a rotating mechanism, and a film comprising a fluorine-containing polymer having a functional group(s) under a fluidized state or a film comprising a fluorine-containing polyurethane compound under a solid state is formed on at least the track surface of the rolling bearing. Since this film does not contain ions for uniformly dispersing a thickner having non uniform particle sizes such as fluorine based grease of the prior art, breakage of the film between a rolling element and a race is not likely to occur, and wear of a rolling element race resulting from the direct contact between them due to breakage of the film can be reduced. When this film is the same kind of a film as a protective film of the surface of an information recording disk, dust generating components of the film are the same kind of components as those of the protective film, and information recording/reproduction of the information recording disk is not impeded.

Description

CSV 포맷 파일 작성방법{CSV REPORT GENERATION}How to create a CV format file {CSV REPORT GENERATION}

본 발명은 CSV 포맷 파일 작성방법에 관한 것이다.The present invention relates to a method for creating a CSV format file.

일반적으로 데이터베이스를 제어하는 프로그램에 있어서는, 사용자가 일단 화면을 통해 검색한 자료를 재 가공해야 할 경우 이를 위해 제작된 전용의 출력용 프로그램을 호출하여 수행하는 경우가 대부분이다.In general, in a program for controlling a database, when a user needs to reprocess the data once retrieved through the screen, it is most often performed by calling a dedicated output program designed for this purpose.

따라서, 이미 제작된 형태의 보고서만 출력이 가능할 뿐이므로, 다른 형태의 보고서를 출력하기 위해서는 재차 프로그램 제작부서 등에 의뢰하여 새로운 보고서 프로그램을 제작하여 사용한다.Therefore, only the report of the already produced form can be outputted, and in order to output another form of report, a new report program is produced and used by requesting the program production department again.

그러나, 이와 같이 제작되는 보고서용 프로그램은 전산전문가가 그 프로그램의 용도인 업무내용을 잘 파악하지 못한 상태에서 제작하는 경우가 태반이고, 현업사용자는 또한 전산에 대해 문외한인 경우가 많으므로 수 차례의 수정작업을 거칠 수밖에 없다.However, the report program produced as described above is often created without a computer expert grasping the business content of the program, and the business user is also often ignorant about computerization. There is no choice but to go through the correction.

더구나, 이와 같이 많은 시간과 인력을 들여 작성한 보고서라 하더라도 집계방식, 출력형태의 변형이 필요하게 되어 유사한 보고서가 점차 늘어나게 되며, 이에 따라 대부분의 사용빈도수가 대단히 낮아지거나 심지어 일회용에 그치는 경우가 많아 시간 및 비용 낭비가 심한 실정이다.Moreover, even with this report, which requires a lot of time and manpower, similar reports are gradually increasing due to the modification of the aggregation method and the output form. As a result, the frequency of use is extremely low or even disposable. And the situation is a waste of money.

따라서, 본 발명은 비 전산 전문가인 사용자가 원하는 형태의 보고서를 만들기 위한 단계에서 엑셀에서 읽어 들일 수 있는 CSV 포맷의 파일을 만드는 단계를 중간단계로 제공함으로써 훨씬 다양한 보고서를 편의대로 만들 수 있는 CSV 포맷 파일 작성방법을 제공하는데 그 목적이 있다.Therefore, the present invention provides a CSV format that can make a much wider range of reports at a convenient level by providing an intermediate step of creating a CSV-formatted file that can be read in Excel in a step for making a report in a form desired by a non-computer expert. Its purpose is to provide a way of creating a file.

도 1은 본 발명의 개념도이다.1 is a conceptual diagram of the present invention.

도 2는 본 발명의 CSV 출력에 코드명 출력이 가능하도록 구성되는 테이블 구성도이다.2 is a table configuration diagram configured to output a code name to the CSV output of the present invention.

도 3은 본 발명의 프로그램 구성도이다.3 is a program configuration diagram of the present invention.

도 4는 본 발명을 실현하기 위한 블록 제어도이다.4 is a block control diagram for implementing the present invention.

도 5는 본 발명의 실시예에 따른 동작 흐름도이다.5 is an operation flowchart according to an embodiment of the present invention.

도 6은 본 발명의 다른 실시예에 따른 동작 흐름도이다.6 is an operation flowchart according to another embodiment of the present invention.

도 7은 본 발명의 전체적인 동작 흐름도이다.7 is a flowchart of the overall operation of the present invention.

도 8은 일반적인 프로그램에서 검색을 마치고 조회하는 화면이다.8 is a screen for searching after completing a search in a general program.

도 9는 도 6의 동작 흐름에 따라 나타나는 화면이다.FIG. 9 is a screen displayed according to the operation flow of FIG. 6.

도 10은 CSV로 출력된 파일을 엑셀에서 읽어 들인 화면이다.10 is a screen of reading a file output in CSV from Excel.

도 11은 리스트 아이템이 존재할 경우를 보여주는 화면이다.11 is a screen illustrating a case where a list item exists.

도 12는 도 10 및 도 11에 의해 변환된 파일을 보여주는 화면이다.12 is a screen illustrating a file converted by FIGS. 10 and 11.

도 13은 관리자가 사용자에 의해 사용될 수 있는 테이블(뷰 테이블 포함)에 한글 이름을 지정하는 화면이다.13 is a screen in which an administrator assigns a Hangul name to a table (including a view table) that can be used by a user.

도 14는 도 13에 의해 테이블의 칼럼에 한글 이름을 붙여주는 화면이다.FIG. 14 is a screen for attaching a Hangul name to a column of a table shown in FIG. 13.

도 15는 일반 사용자가 사용하는 CSV 리포트 작성기의 테이블 선택 화면이다.15 is a table selection screen of the CSV report generator used by a general user.

도 16은 도 15에 의해 칼럼을 선택하는 화면이다.FIG. 16 is a screen for selecting a column according to FIG. 15.

도 17은 도 15에 의해 검색조건을 입력하는 화면이다.17 is a screen for inputting a search condition according to FIG. 15.

* 도면의 주요부분에 대한 부호의 설명 *Explanation of symbols on the main parts of the drawings

70 ------ 검색조건문추출수단 80 ------ 분리수단70 ------ Search condition extraction means 80 ------ Separation means

90 ------ 시스템테이블리드수단 100 ----- 칼럼디스플레이수단90 ------ System table lead means 100 ----- Column display means

110 ----- 칼럼선택수단 120 ----- CSV 출력수단110 ----- Column selection means 120 ----- CSV output means

상기 목적을 달성하기 위한 본 발명의 CSV 포맷 파일 작성방법은, 관리자에 의해 사용자가 검색에 필요한 테이블의 자국어 이름을 지정하는 스텝; 상기 테이블에 구성된 칼럼의 자국어 이름을 지정하는 스텝; 리스트 아이템을 위한 코드값과 코드명을 등록하는 스텝; 사용자가 검색에 활용한 SQL을 축출하여 재활용하는 스텝; 상기 SQL상의 칼럼과 실제 테이블상의 모든 칼럼을 비교하여 화면에 디스플레이하는 스텝; 상기 SQL 재활용 스텝 및 화면 디스플레이 스텝에 의해 실행된 프로그램에서 사용자가 CSV 변환을 위해 적절한 칼럼을 선택하는 스텝; 관리자에 의해 사용자가 이용 가능한 테이블(뷰 테이블 포함)을 등록하는 스텝; 관리자가 등록한테이블 중 사용자가 CSV 출력을 원하는 테이블을 선택하는 스텝; 사용자가 테이블의 전체 칼럼을 대상으로 검색조건을 입력하는 스텝; 사용자가 검색 연산자를 입력하여 이를 LIKE, BETWEEN, IN 등의 RDBMS에서 사용하는 SQL 연산자로 변환하는 스텝; 선택된 칼럼 중 리스트 아이템이 있는지를 판단하여 그 판단결과에 따라 별도의 코드값과 코드명을 참조하여 변환하는 스텝; CSV 포맷 변환을 위한 제어용 SQL을 생성하는 스텝; 선택된 칼럼 중 날짜형식이 있으면 이를 변환하는 스텝; 상기 SQL 변환 스텝 및 리스트 아이템 변환 단계에 의한 변환과정을 거쳐 SQL 문을 생성하는 스텝; 및 상기 SQL 변환 스텝, 리스트 아이템 변환 스텝 및 SQL문 생성 스텝을 통해 SQL을 수행시켜 CSV 포맷 파일을 생성하는 스텝으로 이루어진 것을 특징으로 한다.The CSV format file creation method of the present invention for achieving the above object comprises the steps of: designating, by an administrator, a national language name of a table necessary for a user to search; Designating a national language name of a column configured in the table; Registering a code value and code name for the list item; Extracting and reusing the SQL used by the user for searching; Comparing the columns on the SQL with all the columns on the actual table and displaying them on the screen; Selecting, by the user, an appropriate column for CSV conversion in the program executed by the SQL recycling step and the screen display step; Registering a table (including a view table) available to the user by the administrator; Selecting a table from which the user wants to output CSV from among the tables registered by the administrator; A user inputting a search condition for all columns of the table; A user inputting a search operator and converting the search operator into an SQL operator used in an RDBMS such as LIKE, BETWEEN, and IN; Determining whether there is a list item in the selected column and converting the same by referring to a separate code value and code name according to the determination result; Generating control SQL for CSV format conversion; If there is a date format among the selected columns, converting it; Generating an SQL statement through a conversion by the SQL conversion step and the list item conversion step; And generating a CSV format file by performing SQL through the SQL conversion step, the list item conversion step, and the SQL statement generation step.

이하, 본 발명의 실시예를 첨부한 도면을 참조하여 상세히 설명한다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings.

본 발명은 다음과 같은 두 가지 방법으로 구성된다.The present invention is composed of the following two methods.

즉, (1)사용자가 임의의 조회 프로그램을 통해 조회시 사용된 검색조건문(SQL)을 축출하여 CSV로 출력하는 형태와, (2)전용의 CSV 출력 프로그램을 통해 출력을 원하는 보고서의 종류를 선택하고 검색조건을 입력한 후 CSV로 출력하는 형태이다.That is, (1) user extracts search conditional statement (SQL) used in inquiry through arbitrary inquiry program and outputs it in CSV, and (2) selects the kind of report that wants to output through dedicated CSV output program. After inputting the search condition, it is outputted as CSV.

이를 위해, 본 발명은 도 1에 도시한 바와 같이 사용자(1)가 원하는 형태의 보고서를 만들기 위한 단계에서 CSV 포맷 파일(2)을 만들어 엑셀(3)에서 읽어 들일 수 있도록 한다.To this end, the present invention allows the user 1 to create a CSV format file (2) in the step for creating a report of the desired form to be read in Excel (3).

즉, 본 발명은 C/S와 웹 환경에서 한 번 검색된 화면을 그대로 둔 채 별도의검색조건을 부여하지 않고 MDI 윈도우의 툴바(TOOLBAR)에 위치한 버튼을 누름으로써 기존의 검색조건을 재활용하여 CSV 포맷의 파일을 만든다.In other words, the present invention recycles the existing search condition by pressing a button located in the tool bar of the MDI window without giving a separate search condition while leaving the screen once searched in the C / S and web environments. Create a file for

본 발명은 또한, 사용자가 원하는 보고서를 만들고자 할 때 새로운 보고서를 만드는 것이 아니라, 보고서를 출력할 테이블 혹은 뷰 테이블을 작성하고, 편리하게 이용하도록 한글로 테이블명 혹은 칼럼명을 붙인 후 원하는 조건을 입력하여 재활용이 가능한 CSV 포맷의 보고서를 만들어 준다.In addition, the present invention is not to create a new report when a user wants to create a report, but to create a table or view table for outputting a report, attaching a table name or a column name in Korean for convenient use, and inputting a desired condition. Create a report in CSV format that can be reused.

도 4 내지 도 6을 참조하여 상세히 설명하면, 상기 방법 (1)의 CSV 출력을 위해서는 검색조건문추출수단(70)을 이용하여 사용자가 검색에 사용된 SQL을 추출하고(도 5의 스텝 S1) 분리수단(80)을 이용하여 사용한 테이블, 칼럼과 검색 조건을 분리한 후(도 5의 스텝 S2), 시스템테이블리드수단(90)을 통해 데이터베이스의 시스템 테이블을 읽고(도 5의 스텝 S3), 칼럼디스플레이수단(100)을 통해 SQL에 사용된 칼럼과 테이블에 정의된 나머지 모든 칼럼을 화면에 디스플레이하고(도 5의 스텝 S4), 사용자로 하여금 칼럼선택수단(110)을 통해 필요한 칼럼을 선택하게 한 후(도 5의 스텝 S5), CSV 출력수단(120)을 통해 CSV 출력하도록 한다(도 5의 스텝 S6).4 to 6, in order to output the CSV of the method (1), the user extracts the SQL used for the search using the search condition statement extracting means 70 (step S1 of FIG. 5) and separates it. After separating the used table, column and search condition using the means 80 (step S2 of FIG. 5), the system table of the database is read through the system table reading means 90 (step S3 of FIG. 5), and the column The display means 100 displays the columns used for SQL and all remaining columns defined in the table on the screen (step S4 of FIG. 5), and allows the user to select the necessary columns through the column selection means 110. Subsequently (step S5 of FIG. 5), CSV output is carried out via the CSV output means 120 (step S6 of FIG. 5).

상기 방법 (2)의 CSV 출력을 위해서는 사용자가 검색에 필요한 테이블을 선택한 후(도 6의 스텝 S1), 검색조건을 입력하고(도 6의 스텝 S2), CSV 출력하도록 한다(도 6의 스텝 S3).In order to output the CSV of the method (2), the user selects a table necessary for the search (step S1 in FIG. 6), inputs a search condition (step S2 in FIG. 6), and outputs the CSV (step S3 in FIG. 6). ).

이때, 상기 방법 (1)과 (2) 모두 테이블 혹은 칼럼의 이름은 일반 사용자가 알 수 없는 단어로 구성되는 경우가 대부분이므로 적절한 칼럼명을 자국어로 표기가 가능하도록 한다.At this time, since the names of the tables or columns in both the methods (1) and (2) are mostly composed of words unknown to the general user, appropriate column names can be written in the native language.

또한, 리스트 아이템에 의해 정의된 항목의 경우엔 저장된 코드값과 코드명이 다른 경우가 많으므로 CSV 출력엔 코드명이 함께 출력 가능하도록 한다.In addition, in the case of the item defined by the list item, the stored code value and the code name are often different, so that the code name can be output together with the CSV output.

즉, 리스트 아이템의 경우 코드값은 사용자가 모르는 코드로 되어 있으므로 실제 데이터베이스의 값을 출력하면 보고서의 의미가 반감된다. 따라서, 리스트 아이템은 코드값이 아닌 코드명을 출력하도록 하는 것이다.That is, in the case of the list item, the code value is a code that the user does not know, so the meaning of the report is halved when the actual database value is output. Therefore, the list item is to output the code name, not the code value.

이를 위해, 도 2에 도시한 바와 같이 테이블의 한글명을 저장해 두는 테이블(10)과, 각 칼럼의 테이블을 저장해 두는 테이블(20), 리스트 아이템의 코드값과 코드명을 저장해 두는 테이블(30) 및 이 테이블들을 관리하는 프로그램(50)을 구성한다.To this end, as shown in FIG. 2, a table 10 storing Korean names of tables, a table 20 storing tables of each column, a table 30 storing code values and code names of list items, and A program 50 that manages these tables is configured.

또한, 도 3에 도시한 바와 같이 사용자가 임의의 프로그램에서 사용한 SQL을 이용하여 CSV를 만들어주는 프로그램(60)과 모든 테이블에 대해 검색조건을 입력하고 CSV로 출력하는 프로그램(61)을 구성한다.In addition, as shown in FIG. 3, a program 60 for creating a CSV using SQL used in an arbitrary program and a program 61 for inputting a search condition for all tables and outputting the data as a CSV are configured.

본 발명은, 방법 (1)을 위하여 사용자가 검색에 사용된 SQL을 축출한 후 SQL에서 사용된 테이블과 검색 조건절을 분리한다.The present invention separates the table used in the SQL and the search condition clause after the user has evicted the SQL used for the search for method (1).

이때, 분리된 테이블 정보와 조건절은 방법 (1)을 위한 프로그램에 전달되는데 이 프로그램은 데이터베이스의 시스템 테이블(USER_TAB_COLUMNS)을 읽어 사용 테이블에 지정되어 있는 모든 칼럼을 검색한다.At this time, the separated table information and conditional clause are passed to the program for the method (1). This program reads the system table (USER_TAB_COLUMNS) of the database and searches all columns specified in the usage table.

상기 칼럼은 다시 관리자가 미리 지정해둔 도 13에 도시한 테이블과 도 14에 도시한 칼럼의 한글 이름을 참조하여 사용자의 화면에 한글이름으로 칼럼명이 조회되도록 한다.The column is again referred to by the administrator in advance by referring to the table shown in FIG. 13 and the Hangul name of the column shown in FIG.

도 9에 도시한 바와 같이 사용자가 출력을 원하는 칼럼을 선택한 후 생성 버튼을 누르면 원하는 CSV 출력물을 얻을 수 있게 된다.As shown in FIG. 9, when a user selects a desired column for output and presses a create button, a desired CSV output can be obtained.

방법 (2)를 위해서는 도 10에 도시한 바와 같이 미리 등록된 테이블과 칼럼을 선택한다. 도 15에 도시한 바와 같이 CSV 출력을 위해 검색조건을 입력한다. 이때, 도 17에 도시한 바와 같이 적절한 연산식을 입력하여 다양한 검색이 가능하게 한다.For method (2), previously registered tables and columns are selected as shown in FIG. As shown in FIG. 15, a search condition is input for CSV output. In this case, as shown in FIG. 17, various search is possible by inputting an appropriate expression.

연산식의 활용예를 들면,For example, the use of expressions

AAA로 시작하는 조건 = AAA%Conditions starting with AAA = AAA%

AAA가 중간에 들어간 조건 = %AAA%Intermediate condition with AAA =% AAA%

AAA와 AAB를 동시에 검색하는 조건 = AAA // AABCondition to search AAA and AAB at the same time = AAA // AAB

AAA에서 AAZ의 구간을 검색하는 조건 = AAA .. AAZCondition to retrieve interval of AAZ from AAA = AAA .. AAZ

등을 들 수 있다.Etc. can be mentioned.

가장 널리 사용되는 오라클 RDBMS의 경우 데이터베이스 사용자가 등록한 테이블에 대한 정보는 USER_TABLES에 저장이 되고 칼럼에 대한 정보는 USER_TAB_COLUMNS에 저장되므로 이 두 개의 시스템 테이블을 통해 사용자가 데이터베이스에 등록한 테이블과 그에 해당되는 칼럼 정보를 모두 알 수 있다.In the most widely used Oracle RDBMS, information about tables registered by database users is stored in USER_TABLES, and information about columns is stored in USER_TAB_COLUMNS. You can see all of them.

또한, CSV출력을 위한 기본적인 SQL문은 아래와 같다.Also, the basic SQL statement for CSV output is as follows.

SET LINESIZE 1000;SET LINESIZE 1000;

SET PAGESIZE 0;SET PAGESIZE 0;

SET FEEDBACK OFF;SET FEEDBACK OFF;

SET TERM OFF;SET TERM OFF;

SET HEADING OFF;SET HEADING OFF;

SET COLSEP '","';SET COLSEP '","';

SPOOL xxx.csv;SPOOL xxx.csv;

SELECT '"'|| column1, column2 ||'"' from table_name WHERE ....;SPOOL OFF;SELECT '"' || column1, column2 || '"' from table_name WHERE ....; SPOOL OFF;

칼럼에 날짜가 있을 경우엔 날짜를 문자형으로 변환하는 기법이 필요하다.If the column contains a date, you need a technique to convert the date to a character type.

SELECT '"'|| to_char(column1, 'yyyy-mm-dd'), column2 ||'"' from table_name WHERE....;SELECT '"' || to_char (column1, 'yyyy-mm-dd'), column2 || '"' from table_name WHERE ....;

리스트 아이템이 존재하는 경우엔 코드값과 코드명을 변환하는 기법이 필요하다.If a list item exists, a technique is needed to convert the code value and code name.

SELECT '"'|| decode(column1, 'A','명1', 'B','명2', 'C', '명3', null), column2 ||'"' from table_name WHERE ....;SELECT '"' || decode (column1, 'A', 'name1', 'B', 'name2', 'C', 'name3', null), column2 || '"' from table_name WHERE. ...;

또한, 엑셀의 특성상 각 엑셀의 셀마다 타이틀을 주어야 하므로 타이틀을 작성하는 부분이 제일 앞부분에 추가되어야 한다. 따라서 전체적인 SQL을 보면,In addition, since a title must be given to each cell of Excel due to the characteristics of Excel, a part for creating a title must be added to the front. So if you look at the overall SQL,

SET LINESIZE 1000;SET LINESIZE 1000;

SET PAGESIZE 0;SET PAGESIZE 0;

SET FEEDBACK OFF;SET FEEDBACK OFF;

SET TERM OFF;SET TERM OFF;

SET HEADING OFF;SET HEADING OFF;

SELECT '타이틀1, 타이틀2,...' FROM DUAL;SELECT 'Title 1, Title 2, ...' FROM DUAL;

TITLE OFF;TITLE OFF;

SET COLSEP '","';SET COLSEP '","';

SPOOL xxx.csv;SPOOL xxx.csv;

SELECT '"'|| column1, column2 ||'"' FROM table_name WHERE ....;SPOOL OFF;SELECT '"' || column1, column2 || '"' FROM table_name WHERE ....; SPOOL OFF;

이 된다.Becomes

실제 사용되는 SQL의 예를 들면 아래와 같다.An example of the SQL actually used is as follows.

SET LINESIZE 1000SET LINESIZE 1000

SET PAGESIZE 0SET PAGESIZE 0

SET FEEDBACK OFFSET FEEDBACK OFF

SET TERM OFFSET TERM OFF

SPOOL c:\temp\csvrpt.csvSPOOL c: \ temp \ csvrpt.csv

SET HEADING OFFSET HEADING OFF

select '입력자, 입력일자, 코드1, 코드2, 코드3, 순번, 품셈코드, 품셈구분, 비용구분, 수량' from dual;select 'enter, date input, code1, code2, code3, sequence number, product code, product classification, cost classification, quantity' from dual;

TTITLE OFFTTITLE OFF

SET COLSEP '","'SET COLSEP '","'

col ENTER_DATE for a19col ENTER_DATE for a19

select '"'||ENTER_BY, to_char(ENTER_DATE, 'yyyy-mm-dd hh24:mi'), CODE1, CODE2, CODE3, SEQ_NUM, ACT_NO,decode(ACT_TYPE,'0','정상품목','1','별도품목','2','품셈품목','3','예외품목',null), decode(COST_TYPE,'1','재료비','2','노무비','3','경비', null), QTY||'"' from t2govact_pum where ...order by ...;select '"' || ENTER_BY, to_char (ENTER_DATE, 'yyyy-mm-dd hh24: mi'), CODE1, CODE2, CODE3, SEQ_NUM, ACT_NO, decode (ACT_TYPE, '0', 'regular item', '1' , 'Separate items', '2', 'preparation items', '3', 'exception items', null), decode (COST_TYPE, '1', 'material costs', '2', 'labor costs', '3' , 'Expense', null), QTY || '"' from t2govact_pum where ... order by ...;

SPOOL OFFSPOOL OFF

SET FEEDBACK ONSET FEEDBACK ON

EXITEXIT

상기 SQL에 의한 CSV 출력물은 아래와 같다.The CSV output by the SQL is as follows.

입력자, 입력일자, 코드1, 코드2, 코드3, 순번, 품셈코드, 품셈구분, 비용구분,수량Input method, input date, code 1, code 2, code 3, sequence number, product code, product classification, cost classification, quantity

"KIMS","1999-01-01 12:00","0042","02","01"," 5","11810110","정상품목","재료비",".3""KIMS", "1999-01-01 12:00", "0042", "02", "01", "5", "11810110", "regular item", "material cost", ".3"

"KIMS","1999-01-01 12:00","0042","02","01"," 4","15860160","정상품목","재료비",".00255""KIMS", "1999-01-01 12:00", "0042", "02", "01", "4", "15860160", "Regular Item", "Material Cost", ". 00255"

"KIMS","1999-01-01 12:00","0042","02","01"," 3","15910160","정상품목","재료비",".005832""KIMS", "1999-01-01 12:00", "0042", "02", "01", "3", "15910160", "Regular Item", "Material Cost", ". 005832"

도 7은 본 발명의 전체적인 동작 흐름도로써, 먼저, 관리자에 의해 사용자가 검색에 필요한 테이블의 자국어 이름을 지정하고(스텝 S1), 상기 테이블에 구성된 칼럼의 자국어 이름을 지정하며(스텝 S2), 리스트 아이템을 위한 코드값과 코드명을 등록한다(스텝 S3).Fig. 7 is an overall operation flow chart of the present invention. First, the administrator designates a national language name of a table necessary for a user to search (step S1), a national language name of a column configured in the table (step S2), and a list. The code value and code name for the item are registered (step S3).

이후, 사용자가 검색에 활용한 SQL을 축출하여 재활용하고(스텝 S4), SQL상의 칼럼과 실제 테이블상의 모든 칼럼을 비교하여 화면에 디스플레이한다(스텝 S5).Thereafter, the user extracts and recycles the SQL used for the search (step S4), and compares the columns in the SQL with all the columns in the actual table and displays them on the screen (step S5).

이에 따라, 사용자는 검색에 활용한 SQL을 축출하고, 이 SQL상의 칼럼과 실제 테이블 상의 칼럼을 비교하기 위해 실행된 프로그램에서 CSV 변환을 위해 적절한 칼럼을 선택하게 된다(스텝 S6).Accordingly, the user evicts the SQL used for the search, and selects an appropriate column for CSV conversion in the program executed to compare the column on the SQL with the column on the actual table (step S6).

이와 같은 상태에서 관리자는 사용자가 이용 가능한 테이블을 등록하되 이 테이블에는 뷰 테이블을 포함하도록 한다(스텝 S7).In this state, the administrator registers a table available to the user, but includes the view table in the table (step S7).

사용자는 상기 관리자가 등록한 테이블 중 CSV 출력을 원하는 테이블을 선택하고(스텝 S8), 테이블의 전체 칼럼을 대상으로 검색조건을 입력한다(스텝 S9).The user selects a table for which CSV output is desired from among the tables registered by the administrator (step S8), and inputs a search condition for all columns of the table (step S9).

이후, 사용자가 검색 연산자를 입력하여 이를 LIKE, BETWEEN, IN등의RDBMS에서 사용하는 SQL 연산자로 변환하도록 하고(스텝 S10), 선택된 칼럼 중 리스트 아이템이 있는지를 판단하여, 리스트 아이템이 있으면(스텝 S11의 YES) 별도의 코드값과 코드명을 참조하여 변환하게 된다(스텝 S12).Thereafter, the user inputs a search operator and converts it to an SQL operator used in an RDBMS such as LIKE, BETWEEN, or IN (step S10). YES) Conversion is performed by referring to the other code value and code name (step S12).

리스트 아이템의 변환이 완료되면 CSV 포맷 변환을 위한 제어용 SQL을 생성하고(스텝 S13), 선택된 칼럼 중 날짜형식이 있는지를 판단하여 날짜 형식이 있으면(스텝 S14의 YES) 날짜 형식을 변환하게 된다(스텝 S15).When conversion of the list item is completed, control SQL for CSV format conversion is generated (step S13), and it is determined whether or not there is a date format among the selected columns, and if there is a date format (YES in step S14), the date format is converted (step S13). S15).

이와 같은 상태에서 상기 스텝 S10, S11 및 S12에 의한 변환과정을 거쳐 SQL문을 생성하고(스텝 S16), 사용자가 검색연산자를 입력하여 이를 LIKE, BETWEEN, IN 등의 RDBMS에서 사용하는 SQL 연산자로 변환하는 동작, 선택된 칼럼 중 리스트 아이템을 찾아 별도의 코드값과 코드명을 참조하여 변환하는 동작 및 제어용 SQL을 생성하는 동작이 상기 스텝 S10, S11, S12 및 S13을 통해 수행되었으므로 SQL을 수행시켜 CSV 포맷 파일을 생성하게 된다(스텝 S17).In this state, an SQL statement is generated through the conversion process of steps S10, S11, and S12 (step S16), and the user inputs a search operator and converts it to an SQL operator used in an RDBMS such as LIKE, BETWEEN, IN, and the like. To perform the operation to find the list item in the selected column, convert it by referring to a separate code value and code name, and generate the control SQL through the steps S10, S11, S12, and S13. A file is generated (step S17).

상술한 바와 같이 본 발명을 이용하면, 별도의 개별적인 프로그램이 필요 없이 사용자가 일단 검색에 사용된 SQL을 재활용함으로써 얼마든지 재가공이 가능한 다양한 형태의 보고서 작성이 가능하며, 특히 운영자가 지정해 놓은 모든 테이블(뷰 테이블 포함)에 대해 검색조건을 입력하고 그 출력을 만들 수 있으므로 일회성 보고서의 작성에 활용 가능하게 되어 대단히 편리한 이점이 있다.As described above, using the present invention, it is possible to create various types of reports that can be reprocessed by the user by reusing the SQL once used for retrieval without the need for a separate program, and in particular, all tables designated by the operator ( Search conditions can be entered and output can be generated for the view table (including the view table), which can be used to create a one-time report, which is very convenient.

Claims (2)

관리자에 의해 사용자가 검색에 필요한 테이블의 자국어 이름을 지정하는 스텝;Assigning, by the administrator, a national language name of a table necessary for the user to search; 상기 테이블에 구성된 칼럼의 자국어 이름을 지정하는 스텝;Designating a national language name of a column configured in the table; 리스트 아이템을 위한 코드값과 코드명을 등록하는 스텝;Registering a code value and code name for the list item; 사용자가 검색에 활용한 SQL을 축출하여 재활용하는 스텝;Extracting and reusing the SQL used by the user for searching; 상기 SQL상의 칼럼과 실제 테이블상의 모든 칼럼을 비교하여 화면에 디스플레이하는 스텝;Comparing the columns on the SQL with all the columns on the actual table and displaying them on the screen; 상기 SQL 재활용 스텝 및 화면 디스플레이 스텝에 의해 실행된 프로그램에서 사용자가 CSV 변환을 위해 적절한 칼럼을 선택하는 스텝;Selecting, by the user, an appropriate column for CSV conversion in the program executed by the SQL recycling step and the screen display step; 관리자에 의해 사용자가 이용 가능한 테이블(뷰 테이블 포함)을 등록하는 스텝;Registering a table (including a view table) available to the user by the administrator; 관리자가 등록한 테이블 중 사용자가 CSV 출력을 원하는 테이블을 선택하는 스텝;Selecting a table from which the user wants to output CSV from among the tables registered by the administrator; 사용자가 테이블의 전체 칼럼을 대상으로 검색조건을 입력하는 스텝;A user inputting a search condition for all columns of the table; 사용자가 검색 연산자를 입력하여 이를 LIKE, BETWEEN, IN 등의 RDBMS에서 사용하는 SQL 연산자로 변환하는 스텝;A user inputting a search operator and converting the search operator into an SQL operator used in an RDBMS such as LIKE, BETWEEN, and IN; 선택된 칼럼 중 리스트 아이템이 있는지를 판단하여 그 판단결과에 따라 별도의 코드값과 코드명을 참조하여 변환하는 스텝;Determining whether there is a list item in the selected column and converting the same by referring to a separate code value and code name according to the determination result; CSV 포맷 변환을 위한 제어용 SQL을 생성하는 스텝;Generating control SQL for CSV format conversion; 선택된 칼럼 중 날짜형식이 있으면 이를 변환하는 스텝;If there is a date format among the selected columns, converting it; 상기 SQL 변환 스텝 및 리스트 아이템 변환 단계에 의한 변환과정을 거쳐 SQL문을 생성하는 스텝; 및Generating an SQL statement through a conversion process by the SQL conversion step and the list item conversion step; And 상기 SQL 변환 스텝, 리스트 아이템 변환 스텝 및 SQL 문 생성 스텝을 통해 SQL을 수행시켜 CSV 포맷 파일을 생성하는 스텝으로 이루어진 것을 특징으로 하는 CSV 포맷 파일 작성방법.And generating a CSV format file by performing SQL through the SQL conversion step, list item conversion step, and SQL statement generation step. 제1항에 있어서, 상기 테이블 혹은 칼럼의 이름은 자국어로 표기하고, 리스트 아이템에 의해 정의된 항목의 경우엔 저장된 코드값과 코드명이 다른 경우가 많으므로 CSV 출력시 코드명을 함께 출력하는 것을 특징으로 하는 CSV 포맷 파일 작성방법.The name of the table or column is written in a native language, and in the case of an item defined by a list item, the code name is output when the CSV is output, since the code name is often different from the stored code value. To create a CSV format file.
KR10-2000-0026385A 2000-05-17 2000-05-17 Csv report generation KR100368913B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR10-2000-0026385A KR100368913B1 (en) 2000-05-17 2000-05-17 Csv report generation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR10-2000-0026385A KR100368913B1 (en) 2000-05-17 2000-05-17 Csv report generation

Publications (2)

Publication Number Publication Date
KR20010105679A true KR20010105679A (en) 2001-11-29
KR100368913B1 KR100368913B1 (en) 2003-01-24

Family

ID=19668913

Family Applications (1)

Application Number Title Priority Date Filing Date
KR10-2000-0026385A KR100368913B1 (en) 2000-05-17 2000-05-17 Csv report generation

Country Status (1)

Country Link
KR (1) KR100368913B1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100635733B1 (en) * 2002-09-25 2006-10-17 삼성에스디에스 주식회사 A Proposal Making System And The Method Using The Same
CN107168695A (en) * 2017-04-18 2017-09-15 北京思特奇信息技术股份有限公司 A kind of excel data analysis methods and system

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0887495A (en) * 1994-09-16 1996-04-02 Ibm Japan Ltd Cut amd paste method for table data and data processing system
JPH10289279A (en) * 1997-04-16 1998-10-27 Aibitsukusu Kk System and method for document processing, and recording medium
JPH10326285A (en) * 1997-05-27 1998-12-08 Meidensha Corp Document management system
JPH11242668A (en) * 1998-02-25 1999-09-07 Toshiba Tec Corp General purpose csv file processing system
KR20010099183A (en) * 2001-09-10 2001-11-09 . Data Combination Management System

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100635733B1 (en) * 2002-09-25 2006-10-17 삼성에스디에스 주식회사 A Proposal Making System And The Method Using The Same
CN107168695A (en) * 2017-04-18 2017-09-15 北京思特奇信息技术股份有限公司 A kind of excel data analysis methods and system
CN107168695B (en) * 2017-04-18 2020-07-03 北京思特奇信息技术股份有限公司 Excel data analysis method and system

Also Published As

Publication number Publication date
KR100368913B1 (en) 2003-01-24

Similar Documents

Publication Publication Date Title
RU2427896C2 (en) Annotation of documents in jointly operating applications by data in separated information systems
CN108268617B (en) User intention determining method and device
CN109522480B (en) Information recommendation method and device, electronic equipment and storage medium
US11386081B2 (en) System and method for facilitating efficient indexing in a database system
CN106156103B (en) A kind of search processing method and device
WO2003060771A1 (en) Identifier vocabulary data access method and system
JP2005250699A (en) Hierarchical database device, method for selecting product of hierarchical database device, and program
JP2010039593A (en) Table classification device, table classification method, and table classification program
Özsoyoglu et al. An extension of relational algebra for summary tables
JP2007025868A (en) Category setting support method and device
CN107291951B (en) Data processing method, device, storage medium and processor
JP2009116638A (en) System and method for supporting understanding of business specification
KR20010105679A (en) Csv report generation
JP2004287835A (en) Object table preparation method, object recommendation method, object table preparation program and object recommendation method
JPH11232154A (en) Retrieval method and device for resolving heter-ogeneousness of plural data bases, and recording medium having recorded multi-data base heterogeneousness resolving retrieval program
CN112861060A (en) Page creating method and device, computer equipment and storage medium
JP2001056809A (en) Document managing system
JP2008225584A (en) Article recommendation apparatus, article recommendation system, article recommendation method, and article recommendation program
JP2000163439A (en) Device and method for electronic file retrieval
JPH04319771A (en) On-line information retrieving/updating system
JP2020091630A (en) Document creation assisting system
JPH10177584A (en) Document retrieval system
JP3933407B2 (en) Document processing apparatus, document processing method, and storage medium storing document processing program
JP2004126680A (en) Sql masking type database access method and computer program
KR100519453B1 (en) Apparatus and method for controlling work of database used in object-oriented application

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
LAPS Lapse due to unpaid annual fee