JP2014074947A - Program generation system and program generation method - Google Patents
Program generation system and program generation method Download PDFInfo
- Publication number
- JP2014074947A JP2014074947A JP2012220511A JP2012220511A JP2014074947A JP 2014074947 A JP2014074947 A JP 2014074947A JP 2012220511 A JP2012220511 A JP 2012220511A JP 2012220511 A JP2012220511 A JP 2012220511A JP 2014074947 A JP2014074947 A JP 2014074947A
- Authority
- JP
- Japan
- Prior art keywords
- data
- label
- lowest
- data item
- type
- Prior art date
- Legal status (The legal status 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 status listed.)
- Pending
Links
Images
Landscapes
- Stored Programmes (AREA)
Abstract
Description
本発明は、プログラム生成システムおよびプログラム生成方法に関するものであり、具体的には、スプレッドシートを用いた業務をウェブアプリケーションに移行する際の、ユーザ作業量を効果的に抑制し、ウェブアプリケーションプログラムのコードを効率的に生成する技術に関する。 The present invention relates to a program generation system and a program generation method. Specifically, the present invention relates to a web application program that effectively suppresses the amount of user work when a job using a spreadsheet is transferred to a web application. The present invention relates to a technique for efficiently generating code.
従来、業務処理を実施するためのウェブアプリケーションの構成に際しては、クライアントのブラウザからの要求を処理する要求処理プログラム、業務データを記憶するデータベースとのアクセス処理をするデータベースアクセスプログラム、クライアントのブラウザ画面を生成する画面コード生成プログラム、業務ロジックに応じた情報処理プログラム等、複数のプログラムを準備する必要がある。従って、こうしたウェブアプリケーションを適用するシステム規模が大きくなると、その開発や保守作業のユーザ負担が増大していた。 Conventionally, when configuring a web application for executing business processing, a request processing program for processing a request from a client browser, a database access program for processing access to a database storing business data, and a client browser screen It is necessary to prepare a plurality of programs such as a screen code generation program to be generated and an information processing program according to business logic. Therefore, as the system scale to which such a web application is applied increases, the burden on the user for development and maintenance work increases.
こうした問題に関し、例えば、ウェブアプリケーションの開発を容易に行うことができ、設計開発者の負担を軽減させ、かつ設計開発のスピードアップを図ることができるプログラム生成装置およびプログラム生成方法(特許文献1参照)などが提案されている。
Regarding such problems, for example, a program generation device and a program generation method that can easily develop a web application, reduce the burden on the design developer, and speed up the design development (see
しかしながら、上記のようなプログラム生成方法では、ウェブアプリケーションが処理対象とする業務に関する、業務仕様情報、物理仕様情報、業務パターン情報という基本設計情報を入力として与える必要がある。従来のプログラム生成方法を採用する場合、単純でごく小規模な業務に利用するウェブアプリケーションであっても、上述の基本設計情報の準備作業は当然必要であり、対象ウェブアプリケーションの単純さや小規模さに比して、開発作業の煩雑度が相対的に大きくなりがちである。よって、プログラム生成作業が手間やコストに見合わない非効率的なものとなってしまう問題があった。 However, in the program generation method as described above, it is necessary to provide basic design information such as business specification information, physical specification information, and business pattern information related to a business to be processed by the web application as an input. When adopting the conventional program generation method, even if it is a web application used for simple and very small-scale business, the above basic design information preparation work is naturally necessary. In comparison with this, the complexity of development work tends to be relatively large. Therefore, there is a problem that the program generation work becomes inefficient because it does not meet the labor and cost.
上述した単純で小規模な業務としては、例えば、スプレッドシートを用いた情報集約業務があげられる。この情報集約業務とは、集約主体が、データ項目を記したスプレッドシートを複数ユーザに提示し、各データ項目に関してユーザが回答を行ったスプレッドシートを回収して、データベース等に集計し集約管理する業務である。このような業務は、ウェブアプリケーションに移行できれば処理効率が改善するが、上述したように、複数のウェブアプリケーションの一つ一つに対して、基本設計情報を準備する必要があり、全体として非効率的な開発作業が必要となってしまう。 An example of the simple and small-scale business described above is an information aggregation business using a spreadsheet. In this information aggregation service, the aggregation entity presents a spreadsheet with data items to a plurality of users, collects the spreadsheets that the user has answered for each data item, collects them in a database, etc., and manages them collectively It is business. If such a business can be migrated to a web application, the processing efficiency will improve. However, as described above, it is necessary to prepare basic design information for each of a plurality of web applications. Development work is required.
そこで本発明の目的は、スプレッドシートを用いた業務をウェブアプリケーションに移行する際の、ユーザ作業量を効果的に抑制し、ウェブアプリケーションプログラムのコードを効率的に生成する技術を提供することにある。 SUMMARY OF THE INVENTION An object of the present invention is to provide a technique for effectively suppressing the amount of user work and efficiently generating the code of a web application program when a job using a spreadsheet is transferred to a web application. .
上記課題を解決する本発明のプログラム生成システムは、外部装置との間のデータ入出力を担う入出力部と、スプレッドシートデータを格納した記憶部と、前記スプレッドシートデータにて非空白セルたるデータ項目を検索し、データ項目の配置と各データ項目の値のデータ型を判定し、前記データ項目の配置とデータ型の情報を、記憶部のテーブルに格納する第1処理と、前記判定に際し、判定結果の確認用画面を入出力部に出力し、前記判定結果に対するユーザの確認結果を入出力部を介して受け付けて、当該確認結果で前記テーブルを更新する第2処理と、前記テーブルよりデータ項目の配置およびデータ型の情報を読み出し、前記データ項目とそのデータ型の情報を、記憶部に予め保持するプログラムに設定して、前記データ項目に関して前記データ型での入力を受け付ける入力画面をウェブブラウザに表示させ、ウェブブラウザでの入力データをサーバへ送信させる画面コード生成プログラムを生成する第3処理とを実行する演算部と、を備えることを特徴とする。 The program generation system of the present invention that solves the above problems includes an input / output unit that handles data input / output with an external device, a storage unit that stores spreadsheet data, and data that is a non-blank cell in the spreadsheet data Searching for an item, determining the arrangement of the data item and the data type of the value of each data item, and storing the information of the arrangement and data type of the data item in a table of a storage unit; A determination result confirmation screen is output to the input / output unit, a user confirmation result for the determination result is received via the input / output unit, and the table is updated with the confirmation result. Read the information of the item arrangement and data type, set the data item and the data type information in a program stored in advance in the storage unit, And a third processing unit for executing a third process for generating a screen code generation program for displaying an input screen for accepting input in the data type on a web browser and transmitting the input data on the web browser to the server. It is characterized by that.
また、本発明のプログラム生成方法は、外部装置との間のデータ入出力を担う入出力部と、スプレッドシートデータを格納した記憶部とを備えたコンピュータが、前記スプレッドシートデータにて非空白セルたるデータ項目を検索し、データ項目の配置と各データ項目の値のデータ型を判定し、前記データ項目の配置とデータ型の情報を、記憶部のテーブルに格納する第1処理と、前記判定に際し、判定結果の確認用画面を入出力部に出力し、前記判定結果に対するユーザの確認結果を入出力部で受け付けて、当該確認結果で前記テーブルを更新する第2処理と、前記テーブルよりデータ項目の配置およびデータ型の情報を読み出し、前記データ項目とそのデータ型の情報を、記憶部に予め保持するプログラムに設定して、前記データ項目に関して前記データ型での入力を受け付ける入力画面をウェブブラウザに表示させ、ウェブブラウザでの入力データをサーバへ送信させる画面コード生成プログラムを生成する第3処理と、を実行することを特徴とする。 Further, according to the program generation method of the present invention, a computer including an input / output unit for inputting / outputting data to / from an external device and a storage unit for storing spreadsheet data is used for the non-blank cell in the spreadsheet data. A first process of searching for a data item, determining a data item arrangement and a data type of each data item value, and storing the data item arrangement and data type information in a table of a storage unit; and the determination At this time, a confirmation result confirmation screen is output to the input / output unit, a user confirmation result for the determination result is received by the input / output unit, and the table is updated with the confirmation result. Read the information of the item arrangement and data type, set the data item and the data type information in a program stored in advance in the storage unit, And executing a third process for generating a screen code generation program for displaying an input screen for accepting input in the data type on a web browser and transmitting the input data on the web browser to the server. .
本発明によれば、スプレッドシートを用いた業務をウェブアプリケーションに移行する際の、ユーザ作業量を効果的に抑制し、ウェブアプリケーションプログラムのコードを効率的に生成できる。 ADVANTAGE OF THE INVENTION According to this invention, the amount of user work at the time of shifting the operation | work using a spreadsheet to a web application can be suppressed effectively, and the code | cord | chord of a web application program can be produced | generated efficiently.
以下に本発明の実施形態について図面を用いて詳細に説明する。まずは、本実施形態のプログラム生成システムが生成するウェブアプリケーションの適用対象である、スプレッドシートを用いた情報集約業務の具体的な概念について例示する。ここでの情報集約業務は、データ収集やその集計を主導する集約主体が、複数のユーザに対して、収集したいデータに対応したデータ項目を提示し、その複数のユーザらから回答を得る業務となる。この場合、複数のユーザの各々は、集約主体が提示したデータ項目に関するデータをスプレッドシートにて入力し、これを集約主体に提示することになる。一方、集約主体は、ユーザらから提示された各データをデータベースに登録する。 Embodiments of the present invention will be described below in detail with reference to the drawings. First, a specific concept of information aggregation work using a spreadsheet, which is an application target of a web application generated by the program generation system of the present embodiment, will be exemplified. The information aggregating task is a task in which an aggregation entity that leads data collection and aggregation presents data items corresponding to data to be collected to a plurality of users and obtains responses from the plurality of users. Become. In this case, each of the plurality of users inputs data related to the data items presented by the aggregation entity in a spreadsheet and presents the data to the aggregation entity. On the other hand, the aggregation entity registers each data presented by the users in the database.
図1に、上述したようなスプレッドシートを用いた情報集約業務の概念例を示す。スプレッドシートを用いて情報集約業務を実施する場合、図1に例示するような、データ項目を記したスプレッドシート103を表現するデータファイル104を用いる。はじめに、集約主体101が複数のユーザ102に対し、上述のデータファイル104を電子メール等で配送する。データファイル104を受け取ったユーザ102は、それを編集して各データ項目に関してデータ入力をし、編集済みのデータファイル104を集約主体へ返送する。集約主体は、ユーザらから返送されたデータファイル104より、ユーザによって入力されたデータを抽出し、データベース105へ登録する。データファイル104の配送、返送においては、電子メールやファイルサーバ等が用いられる。
FIG. 1 shows a conceptual example of information aggregation work using a spreadsheet as described above. When the information aggregation work is performed using a spreadsheet, a
図1に示すスプレッドシート103を利用した情報集約業務では、ユーザ102が入力するのは、「申請者、姓」、「申請者、名」、「商品、商品ID」、「商品、個数」、「補助、負担元」、「補助、額」の合計6つのデータ項目である。
In the information aggregation work using the
データ項目「申請者、姓」を構成する「申請者」と「姓」の関係のように、値が設定されたセルすなわち非空白セル同士が、あるデータ項目に関して階層をなして結びついた構造がスプレッドシート103には存在する。「申請者、姓」というデータ項目は、「申請者」という値が設定された非空白セルを上位階層にし、「姓」という値が設定された非空白セルを下位階層にした階層構造を含んでいる。なお、「申請者」や「姓」といった値が設定された単独の非空白セルのみでデータ項目と認識することもできる。従って広義では、上述した、データ項目「申請者、姓」は、「申請者」というデータ項目と「姓」というデータ項目の階層構造とみることも出来る。
As shown in the relationship between “applicant” and “surname” that make up the data item “applicant, surname”, there is a structure in which cells with values, that is, non-blank cells, are linked in a hierarchy with respect to a data item. It exists in the
以下の実施形態においては、こうしてデータ項目を階層構造で区切り、階層構造をなす各要素(例:「申請者」、「姓」)をラベルと呼ぶ。すなわち、1つのデータ項目は1つ以上のラベルにより表現される。また、データ項目の階層構造の最下位に相当するラベルを最下位ラベルと呼び、階層を上がるごとに第1上位ラベル、第2上位ラベル、等と呼ぶ。データ項目「申請者、姓」においては、最下位ラベルは「姓」、第1上位ラベルは「申請者」である。 In the following embodiments, the data items are thus divided into a hierarchical structure, and each element (eg, “applicant”, “last name”) forming the hierarchical structure is referred to as a label. That is, one data item is represented by one or more labels. Further, a label corresponding to the lowest level of the hierarchical structure of the data item is called a lowest level label, and is called a first higher level label, a second higher level label, etc. every time the hierarchy is raised. In the data item “applicant, surname”, the lowest label is “last name” and the first upper label is “applicant”.
また、スプレッドシートにおいて、上述したラベルはセルに記入されている。データ項目内の階層構造は、ラベルの記入されたセルの大きさと配置で表現される。図1に示すスプレッドシートでは、ラベルである「申請者」、「商品」、「補助」の値が記入されたセルは、それぞれ「姓」と「名」、および「商品ID」と「個数」、および「負担元」と「額」の各セルの上側に2セル分の幅をもって配置されている。この配置により、「申請者」は「姓」と「名」の、「商品」は「商品ID」と「個数」の、「補助」は「負担元」と「額」の第1上位ラベルであることが示されている。 In the spreadsheet, the above-described label is written in a cell. The hierarchical structure in the data item is expressed by the size and arrangement of the cell in which the label is written. In the spreadsheet shown in FIG. 1, the cells in which the values of “applicant”, “product”, and “auxiliary” as labels are entered are “last name” and “first name”, and “product ID” and “number”, respectively. , And “payment source” and “forehead” cells are arranged with a width of 2 cells above each cell. With this arrangement, “Applicant” is the first upper label of “Last Name” and “First Name”, “Product” is “Product ID” and “Number”, and “Auxiliary” is the first upper label of “Billing Source” and “Forehead”. It is shown that there is.
また上述した情報集約業務に利用されるスプレッドシートには、データ項目の最下位ラベルを含むセルが、行または列方向に並ぶという特徴がある。図1のスプレッドシート103でも、「姓」、「名」、「商品ID」、「個数」、「負担元」、「額」は最下位ラベルであり、これらは行方向に並んでいる。そして、最下位ラベルの並ぶ方向と階層構造の方向は直交するという特徴もある。図1のスプレッドシート103では、最下位ラベルは行方向に並んでいるのに対し、階層構造の方向は列方向であり、上に隣接するセルに記述されたラベルが、下方のセルに記述されたラベルの上位ラベルになっている。
In addition, the spreadsheet used for the above-described information aggregation work has a feature that cells including the lowest label of data items are arranged in a row or column direction. Also in the
また、情報集約業務に利用されるスプレッドシートでは、1つの上位ラベルはその配下のラベルの集合全体と同等の幅(最下位ラベルが行方向に並ぶ場合)または高さ(最下位ラベルが列方向に並ぶ場合)を持つ。したがって、1つの上位ラベルの幅または高さは、その配下の1つの下位ラベルの幅または高さと等しいか大きい。さらに、1つの階層内のラベルの幅または高さの総和は、同じデータ項目内の階層間で等しいため、上位ラベルでは下位ラベルよりも1つの階層内のラベル個数が少なくなることがほとんどである(上位ラベルと下位ラベルとでセル数が同じ場合のぞく)。図1のスプレッドシート103でも、上位ラベルは3つであるのに対し、最下位ラベルは6つである。
Also, in a spreadsheet used for information aggregation work, one upper label has the same width (when the lowest label is aligned in the row direction) or height (the lowest label is the column direction) If you line up with). Therefore, the width or height of one upper label is equal to or greater than the width or height of one lower label under it. Furthermore, since the sum of the widths or heights of the labels in one hierarchy is the same among the hierarchies in the same data item, the number of labels in one hierarchy is almost smaller in the upper label than in the lower label. (Except when upper and lower labels have the same number of cells). Also in the
なお、情報集約業務に利用されるスプレッドシートでは、図1のスプレッドシ−ト103の「XX集計」や「円」、「個」のように、ラベル以外の要素が記入されるという特徴もある。
Note that the spreadsheet used for information aggregation work has a feature that elements other than labels are entered, such as “XX tabulation”, “yen”, and “pieces” in the
図2は、ウェブアプリケーションを用いた情報集約業務の実施を説明する概念図である。この場合、集約主体は、図1に示すスプレッドシート103のデータファイル104をユーザに配送する代わりに、図2に示すような画面203を表示するウェブアプリケーションを作成し、サーバ201に配置する。ユーザ202はクライアント端末におけるウェブブラウザを用いてサーバ201にアクセスし、このウェブアプリケーションを通じて図1に例示したものと同じ6項目のデータを入力することになる。ウェブアプリケーションはユーザ202からの入力データを、サーバ201ないしサーバ201に接続された他装置のデータベースに記憶するように構成されている。
FIG. 2 is a conceptual diagram for explaining the implementation of the information aggregation work using the web application. In this case, instead of delivering the data file 104 of the
同じ情報集約業務を実施するのであっても、スプレッドシート103を利用するよりもウェブアプリケーションを利用するほうが、データベースへの登録が自動化されており、効率が良い。それにもかかわらず、図1のようなスプレッドシート103を利用して情報集約業務を実施する理由としては、図2のようなウェブアプリケーションを簡単に作成する方法がないことが挙げられる。したがって、従来スプレッドシート103を利用して実施していた情報集約業務を、簡単な手順でウェブアプリケーションに移行することができれば、利便性が高い。そこで、本実施形態のプログラム生成システムにおいては、情報集約業務で利用しているスプレッドシート103を入力とし、同様の情報集約業務を実施するためのウェブアプリケーションを生成する。
Even if the same information aggregating operation is performed, registration in the database is automated and efficiency is higher when the web application is used than when the
−−−第1の実施形態−−−
続いて第1の実施形態における、プログラム生成システム303の構成について説明する。図3は第1の実施形態におけるプログラム生成システム303の構成例を表すブロック図である。プログラム生成システム303は、スプレッドシート103を用いた業務をウェブアプリケーションに移行する際の、ユーザ作業量を効果的に抑制し、ウェブアプリケーションプログラムのコードを効率的に生成するためのコンピュータシステムである。
--- First Embodiment ---
Next, the configuration of the
このプログラム生成システム303には、上述した集約主体等からの指示を受け付けるキーボードやマウス等の入力装置301と、処理結果を担当者等に提示するディスプレイ等の表示装置302が接続されている。これらの接続は直接接続であっても良いし、または通信回線や他の情報端末を介した接続であっても良い。
The
プログラム生成システム303は、データ項目・型判定部304、コード生成部305、および画面制御部306の各機能部と、記憶部307とを備えている。各機能部は、例えばプログラム生成システム303が備えるプログラムを実行することで実装されるものと言える。
The
そのうち、データ項目・型判定部304は、上述したスプレッドシート103のデータファイル104からスプレッドシートデータを読み込み、情報集約業務の対象となるデータ項目の配置とその型を判定し、データ項目・型テーブル308として記憶部307に格納する機能を備える。
Among them, the data item /
また、コード生成部305は、記憶部307に格納されたデータ項目・型テーブル308から、データ項目とその型に関する情報を読み出し、要求処理プログラムコード309、データベースアクセスプログラムコード310、画面コード生成プログラムコード311を生成して記憶部307に格納し、さらにデータベース312を構築する機能を備える。
Also, the
また、画面制御部306は、データ項目・型判定部304の処理過程において、表示装置302へ情報を提示する画面を表示し、さらには入力装置301より入力操作を受け付け、入力により生成された情報をデータ項目・型判定部304へ渡す機能を備える。
In addition, the
なお、記憶部307は、図3のようにプログラム生成システム303に含まれる構成としても良いし、プログラム生成システム303に外部接続される構成でも良い。
The
図4はプログラム生成システム303が生成する要求処理プログラム405、データベースアクセスプログラム406、画面コード生成プログラム407からなるウェブアプリケーションシステムの構成例を示す図である。
FIG. 4 is a diagram illustrating a configuration example of a web application system including a
上述したコード生成部305によって生成された要求処理プログラムコード309、データベースアクセスプログラムコード310、画面コード生成プログラムコード311は、それぞれ実行可能な状態でサーバ402に配置され、それぞれ、要求処理プログラム405、データベースアクセスプログラム406、画面コード生成プログラム407を構成する。また、データベース408は情報集約業務の対象となるデータ項目に対応する入力データを格納できるように構成されている。
The request
ウェブアプリケーションシステムは、クライアント401のウェブブラウザ403から利用される。ウェブブラウザ403がサーバ402のウェブアプリケーション(情報集約のためのアプリケーション)にアクセスすると、サーバ402の画面コード生成プログラム407は、上述してきた各データ項目(スプレッドシート103由来のもの)の情報を所定の画面データのひな型にはめ込んで画面コード404を生成し、ウェブブラウザ403に送信する。ウェブブラウザ403は、受信した画面コード404を画面に表示する。
The web application system is used from the
一方、クライアント401のウェブブラウザ403から、上述の画面コード404に対応した表示画面での入力データを含むリクエストがサーバ402へ送信されると、要求処理プログラム405が起動される。要求処理プログラム405は、ウェブブラウザ403のリクエストから入力データを受け取る。さらに要求処理プログラム405は、データベースアクセスプログラム406を起動し、これに入力データを受け渡して処理の実行を要求する。
On the other hand, when a request including input data on a display screen corresponding to the above-described
データベースアクセスプログラム406は、入力データを要求処理プログラム405より受け取って、これをデータベース408に登録し、その実行結果を要求処理プログラム405へ返す。要求処理プログラム405は、データベースアクセスプログラム406の実行結果を、ウェブブラウザ403に対してレスポンスとして返信する。
The
なお、プログラム生成システム303は、一般的なコンピュータ上に実現することが可能である。図5はプログラム生成システム303の機能を実現するコンピュータのハードウェア構成例を示す図である。
The
プログラム生成システム303たるコンピュータは、CPU(Central Processing Unit)502、RAM(Random Access Memory)503、ROM(Read Only Memory)504、HDD(Hard Disk Drive)505、通信インターフェイス(I/F)506、入出力インターフェイス(I/F)507、およびメディアインターフェイス(I/F)508を備える。
A computer serving as the
CPU502は、ROM504またはHDD505に格納されたプログラムに基づいて動作し、各部の制御を行う。ROM504は、コンピュータの起動時にCPUが実行するブートプログラムや、ハードウェアに依存するプログラム等を格納する。
The
HDD505は、CPU502によって実行されるプログラムおよび当該プログラムに使用されるデータを格納する。通信インターフェイス506は、通信媒体520を介して他の機器からデータを受信してCPU502へ送るとともに、CPU502が生成したデータを、通信媒体520を介して他の機器へ送信する。
The
CPU502は入出力インターフェイス507を介して、ディスプレイ等の表示装置302およびキーボードやマウス等の入力装置301を制御する。すなわちCPU502は、生成したデータを、入出力インターフェイス507を介して表示装置302へ出力し、また、入出力インターフェイス507を介して入力装置301からデータを取得する。
The
メディアインターフェイス508は、記録媒体530に格納されたプログラムまたはデータを読み取り、RAM503を介してCPU502に提供する。CPU502は、当該プログラムを、メディアインターフェイス508を介して記録媒体530からRAM503上にロードし、ロードしたプログラムを実行する。記録媒体530は、例えばDVD(Digital Versatile Disk)、PD(Phase change rewritable Disk)等の光学記録媒体、MO(Magneto-Optical disk)等の光磁気記録媒体、テープ媒体、磁気記録媒体、または半導体メモリ等である。
The
こうしたコンピュータがプログラム生成システム303として機能する場合、CPU502は、RAM503上にロードされたプログラムを実行することにより、データ項目・型判定部304、コード生成部305、画面制御部306の各機能を実現する。また、ROM504またはHDD505には、記憶部307内のデータが格納される。コンピュータは、これらのプログラムを、記録媒体530から読み取って実行するが、他の例として、他の装置から、通信媒体520を介してこれらのプログラムを取得してもよい。通信媒体520とは、通信回線、または、当該通信回線を伝搬する搬送波やデジタル信号を指す。
When such a computer functions as the
図6は第1の実施形態におけるプログラム生成方法の処理手順例1を示すフロー図であり、具体的には、プログラム生成システム303によるウェブアプリケーションの生成の一例を示すフローチャートである。
FIG. 6 is a flowchart showing a processing procedure example 1 of the program generation method according to the first embodiment. Specifically, the flowchart shows an example of generation of a web application by the
この場合、プログラム生成システム303のデータ項目・型判定部304が、スプレッドシート103のデータファイル104を、記憶部307ないし入力装置301から読み込むことで、ウェブアプリケーションの生成処理を開始する(S101)。こうした処理の契機は、例えば、プログラム生成システム303が、入力装置301でユーザ指示を受けた時、或いは、予め決められた所定時刻の到来をクロック機能(コンピュータが一般に備えるもの)で検知した時、または、入力装置301からスプレッドシート103のデータファイル104が入力された時、などが想定できる。
In this case, the data item /
続いてデータ項目・型判定部304は、データ項目判定処理を実施する(S102)。データ項目・型判定部304は、データ項目判定処理S102において、上述したステップS101で読み込んだスプレッドシート103のデータファイル104からスプレッドシートデータを取得し、このスプレッドシートデータを解析し、その階層構造を含めたデータ項目の判定を行う。この処理の詳細については後述する。
Subsequently, the data item /
また、データ項目・型判定部304は、データ型判定処理を実施する(S103)。データ項目・型判定部304は、データ型判定処理S103において、上述したデータ項目判定処理S102で判定したデータ項目の最下位ラベルと、後述するラベル・型対応リスト313、文字・型対応リスト314とを比較することで、該当データ項目のデータ型を判定する。
In addition, the data item /
さらに、データ項目・型判定部304は、データ項目・型確認処理を実施する(S104)。データ項目・型判定部304は、データ項目・型確認処理S104において、上述したデータ項目判定処理S102およびデータ型判定処理S103で判定したデータ項目とその型を、画面制御部306を介して表示装置302に表示し、集約主体等のユーザが確認できるようにする。さらにデータ項目・型判定部304は、入力装置301に対する集約主体等のユーザの操作を、画面制御部306を介して受け取り、ユーザの操作内容が示す、データ項目とその型に関する削除、修正、追加等の各種処理を実施する。本処理によりデータ項目・型テーブル308に、判定結果であるデータ項目とその型が記憶される。
Further, the data item /
次に、コード生成部305は、コード生成処理を実施する(S105)。コード生成部305は、コード生成処理S105において、データ項目・型テーブル308よりデータ項目とその型の情報を読み取り、これらの情報を用いて、データベース312を構築し、さらに、要求処理プログラムコード309、データベースアクセスプログラムコード310、画面コード生成プログラムコード311を生成する。生成した各プログラムコードは記憶部307に格納される。
Next, the
図7は、第1の実施形態におけるプログラム生成方法の処理手順例2を示すフロー図であり、具体的には、データ項目・型判定部304の実施するデータ項目判定処理S102の一例を示すフローチャートである。
FIG. 7 is a flowchart showing a processing procedure example 2 of the program generation method in the first embodiment, and specifically, a flowchart showing an example of the data item determination processing S102 performed by the data item /
この場合、データ項目・型判定部304は、スプレッドシート103からスプレッドシートデータを読み取り、図8Aに基づき後述する方法により、行や列ごとの非空白セルの連なりの個数をカウントする(S201)。
In this case, the data item /
次にデータ項目・型判定部304は、すべての行、列の中で、カウントが最大のものに含まれる、最も連続した非空白セルすなわち最大連続非空白セルを特定し、その記入内容を最下位ラベルとする(S202)。
Next, the data item /
最後に、データ項目・型判定部304は、階層構造判定処理を実施する(S203)。階層構造判定処理S203は、最下位ラベルの各々について、その上位ラベルをスプレッドシートから判定する処理である。
Finally, the data item /
図8Aは、非空白セル連なりの個数カウント方法例1を説明する概念図であり、図8Bは非空白セル連なりの個数カウント方法例2を説明する概念図である。 FIG. 8A is a conceptual diagram for explaining a first example of number counting method for a series of non-blank cells, and FIG. 8B is a conceptual diagram for explaining a second example of number counting method for a series of non-blank cells.
スプレッドシート103において、罫線に囲まれた矩形領域をセルと呼ぶ。本実施形態では、値が何も記入されていないセルを「空白セル」、空白セルでないセルを「非空白セル」と呼ぶ。すべてのセルは、空白セルか非空白セルのいずれかである。複数のセルを連結して形成された大きいセルも、空白セル、非空白セルのいずれかである。
In the
非空白セル連なりの個数のカウントには、行単位のカウントと列単位のカウントがある。いずれのカウントにおいても、スプレッドシート103を構成するセルを、スプレッドシート103の端から順に参照し、連続する非空白セルの個数の最大値をカウントとする。カウントする行または列にかかる連結されたセル(複数セルが連結され大型の単体セルとなったもの)は、当該行単位または列単位のカウントの対象とする。そのため、連結されたセルが非空白セルであった場合は、当該連結セルは複数の行単位のカウントの対象、または複数の列単位のカウントの対象となる。
The count of the number of non-blank cells is divided into a row unit count and a column unit count. In any count, cells constituting the
図8Aのスプレッドシート103の行および列の端の矢印の先に、カウントを表す数値を示した。本実施形態では、番号nを用いて、第n行を「Rn」、第n列を「Cn」と表す。また、行および列のカウントを求める関数を表す記号を「N」とする。
A numerical value representing the count is shown at the end of the arrow at the end of the row and column of the
例えば図8Aにおいて、行方向のカウントが最大であるのは行「R4」であり、そのカウントは、N(R4)=6である。また列方向のカウントが最大であるのは列「C1」と「C2」であり、そのカウントは、N(C1)=N(C2)=3である。 For example, in FIG. 8A, the row “R4” has the largest count in the row direction, and the count is N (R4) = 6. In addition, the columns “C1” and “C2” have the largest counts in the column direction, and the counts are N (C1) = N (C2) = 3.
列「C5」の列単位のカウントでは、連続する非空白セルが2箇所に分かれていることに注意する。この列「C5」で連続する非空白セルは「購入品」、「金額」の部分(非空白セルの連続個数は“2”)で、あとは、セル数が1で非連続の「提出YY」の部分である。これらのうち個数が大きい前者の個数が列「C5」のカウントとされ、N(C5)=2となる。列「C6」についても同様にN(C6)=2である。 Note that in the column-by-column count of column “C5”, consecutive non-blank cells are divided into two locations. In this column “C5”, the continuous non-blank cells are “purchased product” and “money” (the number of non-blank cells is “2”), and the number of cells is 1 and the non-continuous “submission YY” "Is the part. Among these, the number of the former having a large number is set as the count of the column “C5”, and N (C5) = 2. Similarly for the column “C6”, N (C6) = 2.
図8Bにおいても同様にカウントが求められる。図8Bは図8Aに比べ、列方向のカウントが大きい傾向にある例である。図8Bにおいて、行方向のカウントが最大であるのは行「R2」、「R3」、「R4」、「R5」であり、そのカウントは、いずれも「2」である。また列方向のカウントが最大であるのは列「C3」であり、そのカウントは、N(C3)=5である。 The count is similarly obtained in FIG. 8B. FIG. 8B is an example in which the count in the column direction tends to be larger than that in FIG. 8A. In FIG. 8B, the row direction counts are the largest in rows “R2”, “R3”, “R4”, and “R5”, and the counts are all “2”. In addition, the column “C3” has the largest count in the column direction, and the count is N (C3) = 5.
図9は第1の実施形態におけるプログラム生成方法の処理手順例3を示すフロー図であり、具体的には、データ項目・型判定部304が実施する階層構造判定処理S203の一例を示すフローチャートである。階層構造判定処理S203の実施時点では、前に実施される処理S202によってスプレッドシートデータに含まれる最下位ラベルの並び方向、および最下位ラベルが特定された状態にある。
FIG. 9 is a flowchart showing a processing procedure example 3 of the program generation method according to the first embodiment. Specifically, the flowchart shows an example of a hierarchical structure determination process S203 performed by the data item /
データ項目・型判定部304が実行する階層構造判定処理S203は、図10Bに示すような階層構造判定表315を作成し、最下位ラベルのそれぞれについて、スプレッドシートデータからその上位ラベルを判定する処理である。上位ラベルは、最下位ラベルの位置より上方向かあるいは左方向に探索される。ここに探索の方向を「D」とし、最下位ラベルの並び方向が行の場合「上」方向、最下位ラベルの並び方向が列の場合「左」方向、と定める。
The hierarchical structure determination processing S203 executed by the data item /
データ項目・型判定部304は、最初の最下位ラベルを仮採用し、最初の最下位ラベルの位置へ探索位置を移動する(S301)。次に、データ項目・型判定部304は、最下位ラベル、項目名、D端位置を、階層構造判定表315へ記憶する(S302)。
The data item /
ここで項目名とは、仮採用したラベルを連結した文字列を表す。ラベルの連結は、仮採用しているうちで最上位のラベルから始まり、階層順に最下位ラベルまでを、例えば、カンマ(「,」)を区切りとして連結する。ただし、S302時点では上位ラベルは仮採用されておらず、項目名は最下位ラベルに一致する。また、D端位置とは探索位置の行位置(Dが「上」の場合)または列位置(Dが「左」の場合)を表す。 Here, the item name represents a character string obtained by concatenating labels temporarily adopted. The concatenation of labels starts from the highest label among tentatively adopted, and concatenates up to the lowest label in the hierarchical order, for example, with a comma (“,”) as a delimiter. However, the upper label is not temporarily adopted at S302, and the item name matches the lowest label. The D end position represents the row position (when D is “up”) or the column position (when D is “left”) of the search position.
次にデータ項目・型判定部304は、探索位置のD方向に非空白セルが隣接するか否かを判定する(S303)。探索位置のD方向に非空白セルが隣接する場合(S303:YES)、データ項目・型判定部304は、探索位置をD方向へ移動し、さらに当該非空白セルに記入されている内容を上位ラベルとして仮採用し、最下位ラベル、項目名、D端位置を階層構造判定表315へ記憶する(S304)。
Next, the data item /
一方、探索位置のD方向に非空白セルが隣接しない場合(S303:NO)、データ項目・型判定部304は、階層構造の判定を実施していない最下位ラベルが残っているか否かを判定する(S305)。階層構造の判定を実施していない最下位ラベルが残っている場合(S305:YES)、データ項目・型判定部304は、すべての仮採用を削除し、次の最下位ラベルを仮採用し、さらに探索位置を当該最下位ラベルの位置へ移動する(S306)。そして処理をS302へ戻す。
On the other hand, when a non-blank cell is not adjacent in the D direction of the search position (S303: NO), the data item /
他方、階層構造の判定を実施していない最下位ラベルが残っていない場合(S305:NO)、データ項目・型判定部304は、階層構造判定表315を探索し、全ての最下位ラベルに共通するD端位置のうち、最もD位置にある記憶を、最下位ラベルごとに採用し(S307)、階層構造判定処理S203を終了する。
On the other hand, when there is no lowermost label that has not been subjected to the determination of the hierarchical structure (S305: NO), the data item /
図10Aは、データ項目判定処理の概念例を示す図であり、図10Bは階層構造判定表315の例を示す図である。ここで、図10Aは、プログラム生成システム303に読み込まれたスプレッドシート103であり、スプレッドシート103の行および列の端の矢印の先に非空白セル連なりのカウント結果を表す数値を示している。また、図10Bは、当該スプレッドシート103に対するデータ項目判定処理で生成される階層構造判定表315である。
FIG. 10A is a diagram illustrating a conceptual example of the data item determination process, and FIG. 10B is a diagram illustrating an example of the hierarchical structure determination table 315. Here, FIG. 10A is the
データ項目・型判定部304は、図10Aに示すとおり、スプレッドシート103における、行、列ごとの非空白セルの連なりの個数をカウントする。本例では、第4行「R4」がカウント最大の行/列であるため、第4行「R4」に含まれる「A」、「B」、「C」、「D」が最下位ラベルであると判定する。
As shown in FIG. 10A, the data item /
また、データ項目・型判定部304は、階層構造判定処理S203を実施する。まず、最下位ラベルの一つ、「A」を仮採用し、探索位置を「A」の位置に設定する。そして、「A」の行位置は「R4」であるため、最下位ラベル、項目名、上端位置として、「A」、「A」、「R4」を階層構造判定表315へ記憶する。
In addition, the data item /
次にデータ項目・型判定部304は、探索位置「A」の上方向の隣接を確認し、非空白セル「E」を参照する。そして、探索位置を「E」セルの位置へ移動し、「E」を上位ラベルに仮採用する。また、データ項目・型判定部304は、この「E」の行位置は「R3」であるため、最下位ラベル、項目名、上端位置として、「A」、「E,A」、「R3」を階層構造判定表315へ記憶する。
Next, the data item /
同様に、データ項目・型判定部304は、探索位置「E」の上方向の隣接を確認し、非空白セル「H」を参照する。そしてデータ項目・型判定部304は、最下位ラベル、項目名、上端位置として、「A」、「H,E,A」、「R2」を階層構造判定表315へ記憶する。
Similarly, the data item /
図の例では、非空白セル「H」の上方向には非空白セルは隣接していない。そのため、データ項目・型判定部304は、最下位ラベル「A」に対する階層構造判定表315への最下位ラベル、項目名、上端位置の各情報の書込みを終了し、すべての仮採用を削除、次の最下位ラベル、例えば「B」を仮採用、探索位置を「B」の位置へ設定し、以降、「B」に対する階層構造判定表315の記憶を実施する。
In the example of the figure, the non-blank cell is not adjacent in the upward direction of the non-blank cell “H”. Therefore, the data item /
このように、「B」、「C」、「D」に対しても、「A」と同様の手順で階層構造判定表315への情報の書込を実施し、データ項目・型判定部304は、図10Bに示す階層構造判定表315を得る。
As described above, information is written to the hierarchical structure determination table 315 in the same procedure as “A” for “B”, “C”, and “D”, and the data item /
そしてデータ項目・型判定部304は、完成した階層構造判定表315を探索し、全ての最下位ラベルに共通する上端位置を求める。本例では上端位置は、最下位ラベル「A」と「B」に対しては「R2」、「R3」、「R4」が記憶されており、最下位ラベル「C」と「D」に対しては「R3」と「R4」が記憶されている。すなわち全ての最下位ラベルに共通する上端位置は「R3」と「R4」であり、このうちでもっとも上に位置するのは「R3」である。したがって、階層構造判定表315にある上端位置が「R3」の記憶を最下位ラベルごとに採用する。よって本例におけるデータ項目判定処理S102の結果は、階層構造を含めたデータ項目として、「E,A」、「F,B」、「G,C」、「G,D」となる。
Then, the data item /
図11は第1の実施形態におけるプログラム生成方法の処理手順例4を示すフロー図であり、具体的には、データ項目・型判定部304の実施するデータ型判定処理S103の一例を示すフローチャートである。データ型判定処理S103の実施時点では、前に実施されるデータ項目判定処理S102によって、スプレッドシートデータに含まれるデータ項目が、階層構造まで含めて特定された状態にある。この場合、データ型判定処理S103は、図12Aに示すラベル・型対応リスト313や、図12Bに示す文字・型対応リスト314を利用して、データ項目の値の型を判定する処理となる。2つのリスト313、314を利用してデータ項目の型を判定できない場合は、あらかじめ定めた型(デフォルトの型、例えばテキスト型)が設定される。
FIG. 11 is a flowchart showing a processing procedure example 4 of the program generation method in the first embodiment. Specifically, the flowchart shows an example of the data type determination processing S103 performed by the data item /
この場合、データ項目・型判定部304は、例えば階層構造判定表315における、例えば最上段のレコードを最初のデータ項目とし、これに対して型判定処理を開始する(S401)。データ項目・型判定部304は、処理対象のデータ項目の最下位ラベルを、ラベル・型対応リスト313に照合し、最下位ラベルの値がラベル・型対応リスト313に存在するか否かを判定する(S402)。
In this case, the data item /
対象のデータ項目の最下位ラベルがラベル・型対応リスト313に存在している場合(S402:YES)、データ項目・型判定部304は、対象のデータ項目の型を、ラベル・型対応リスト313において最下位ラベルの値と対応付けて記述されている型に決定し(S403)、処理をS406へ進める。なお、データ項目・型判定部304は、決定した型の情報を、階層構造判定表315における該当データ項目と対応付けて記憶するものとする(以下同様)。
When the lowest label of the target data item exists in the label / type correspondence list 313 (S402: YES), the data item /
一方、対象のデータ項目の最下位ラベルがラベル・型対応リスト313に存在していない場合(S402:NO)、データ項目・型判定部304は、対象のデータ項目の最下位ラベルを文字・型対応リスト314に照合し、型を決定できるか否か判定する(S404)。具体的には、文字・型対応リスト314に記述された「文字」の中に、最下位ラベルの末尾文字と一致するものがあるか否かデータ項目・型判定部304が判定する。
On the other hand, when the lowest label of the target data item does not exist in the label / type correspondence list 313 (S402: NO), the data item /
文字・型対応リスト314に掲載された「文字」の中に、最下位ラベルの末尾文字と一致するものがあった場合(S404:YES)、データ項目・型判定部304は、対象データ項目の型を、文字・型対応リスト314で一致した「文字」に対応する「型」に決定し(S403)、処理をS406へ進める。他方、一致するものがない場合(S404:NO)、データ項目・型判定部304は、対象データ項目の型をデフォルトの型に決定し(S405)、処理をS406へ進める。
If any of the “characters” listed in the character /
処理S406において、データ項目・型判定部304は、型判定をまだ実施していないデータ項目が階層構造判定表315に残っているか否かを判定する。型判定をまだ実施していないデータ項目が残っている場合(S406:YES)、データ項目・型判定部304は、次のデータ項目の型判定処理に移り(S407)、処理をS401へ戻す。階層構造判定表315におけるすべてのデータ項目に対して型判定を実施した場合(S406:NO)、データ項目・型判定部304は、型判定処理S103を終了する。
In step S <b> 406, the data item /
図13は、第1の実施形態におけるプログラム生成方法の処理手順例5を示すフロー図であり、具体的には、データ項目・型判定部304の実施するデータ項目・型確認処理S104の一例を示すフローチャートである。
FIG. 13 is a flowchart showing a processing procedure example 5 of the program generation method in the first embodiment. Specifically, an example of the data item / type confirmation processing S104 performed by the data item /
この場合、データ項目・型判定部304は、上述のデータ項目判定処理S102およびデータ型判定処理S103によって決定した、データ項目・型のリストを含んだ確認画面を、画面制御部306を介して表示装置302に表示する(S501)。この確認画面は、データ項目・型判定部304が、例えば図14のような確認画面1400の画面フォーマットに対し、上述の処理S102および処理S103で決定した、例えば階層構造判定表315に含まれるデータ項目やその型の情報を、予め定めた配置で設定して、画面データを生成したものとなる(他の画面データ生成も同様)。この画面データは、表示装置302(或いはクライアント401の表示装置。以下同様)に出力され、確認画面1400となる。これによって、集約主体等のユーザが、現時点で決定しているデータ項目・型が確認できる。
In this case, the data item /
続いてデータ項目・型判定部304は、上述の確認画面1400における、入力装置301での集約主体等のユーザ操作を、画面制御部306を介して受け取り、データ項目削除(S502)、データ項目修正(S504)、データ項目追加(S507)を指定する操作内容に応じて、各ステップを実施する。
Subsequently, the data item /
この場合、データ項目・型判定部304は、データ項目削除ステップを、図14の確認画面1400における削除ボタン1401が押下された操作(S502:YES)に従って実行し、確認画面1400にて選択されたデータ項目、すなわち削除ボタン1401が押下されたデータ項目を、階層構造判定表315より削除する(S503)。そしてデータ項目・型判定部304は、この階層構造判定表315に基づいて、図15のように該当データ項目が減少した確認画面1410を表示装置302に表示する(S501)。
In this case, the data item /
また、データ項目・型判定部304は、データ項目修正ステップを、図14の確認画面1400における修正ボタン1402が押下されたる操作(S504:YES)に従って実行し、確認画面1400にて選択されたデータ項目、すなわち修正ボタン1402が押下されたデータ項目を修正する処理を開始する。この場合、データ項目・型判定部304は、図16Aに示すような、最下位ラベル、型の修正画面1600を表示装置302に表示する(S505)。
Further, the data item /
この修正画面1600では、初期状態において、確認画面1400で修正対象としてユーザ選択されたデータ項目の最下位ラベルと型が表示されており、それらは入力装置301の操作によって修正ができる状態になっている。この修正画面1600において、最下位ラベルと型の修正操作と、決定ボタン1601の押下操作を受け付けることによって、データ項目・型判定部304はさらに、図16Bに示すような上位ラベルの修正画面1610を表示装置302に表示する(S506)。
In the
上位ラベル修正画面1610では初期状態において、上述の修正画面1600で修正対象として選択されたデータ項目の上位ラベルが表示されており、入力装置301の操作によって、修正ができる状態になっている。この上位ラベル修正画面1610において、上位ラベルの修正操作と決定ボタン1602の押下操作を受け付けることによって、データ項目・型判定部304は、階層構造判定表315での該当データ項目の修正を実行し、修正されたデータ項目を反映したデータ項目・型のリストを、画面制御部306を介して表示装置302に表示する(S501)。
On the upper
また、データ項目・型判定部304は、データ項目追加ステップを、図14の確認画面1400における追加ボタン1403が押下された操作(S507:YES)に従って実行し、図17Aに示すような、最下位ラベル、型の追加画面1700を表示装置302に表示する(S508)。この最下位ラベル、型追加画面1700では、新たな最下位ラベルと型を入力装置301の操作によって入力ができる状態になっている。この最下位ラベル、型追加画面1700において、最下位ラベルと型の入力操作と決定ボタン1701の押下操作を受け付けることによって、データ項目・型判定部304はさらに、図17Bに示すような上位ラベルの追加画面1710を表示装置302に表示する(S509)。上位ラベル追加画面1700では、該当データ項目の新たな上位ラベルが、入力装置301の操作によって、入力ができる状態になっている。この上位ラベル追加画面1710において、上位ラベルの入力操作し決定ボタン1702の押下操作を受け付けることによって、データ項目・型判定部304は、階層構造判定表315におけるデータ項目の追加を実行し、追加されたデータ項目を反映したデータ項目・型のリストを、画面制御部306を介して表示装置302に表示する(S501)。
Further, the data item /
さらにデータ項目・型判定部304は、図14の決定ボタン1404を押下する操作に従って、階層構造判定表315に対応付けておいたデータ項目とそのデータ型の情報を、データ項目・型テーブル308に記憶し(S510)、データ項目・型確認処理S104を終了する。
Further, the data item /
図18は、第1の実施形態におけるプログラム生成方法の処理手順例6を示すフロー図であり、具体的には、コード生成部305の実施するコード生成処理S105の一例を示すフローチャートである。
FIG. 18 is a flowchart illustrating a processing procedure example 6 of the program generation method according to the first embodiment, and specifically, a flowchart illustrating an example of the code generation processing S105 performed by the
この場合、まずコード生成部305は、上述したデータ項目・型テーブル308に記憶された各データ項目およびその型の情報を読み出し、該当データ項目に対するユーザ入力データを記憶するためのデータベースを記憶部307に構築する(S601)。例えば、コード生成部305は、データ項目を表す列と該当データ項目に関するユーザ入力データを格納する列(この列に入る値は、該当データ項目の型となる)とを対応付けたテーブルをデータベースに作成するための命令文(SQL文など)を生成し、データベースに実行させる。コード生成部305は、こうした命令文を生成するため、所定の構造を備える関係データベースの作成命令に対応したコードのひな形を保持しており、このひな形における所定箇所に上述のデータ項目と型の情報を設定し、命令文を生成する。
In this case, the
次に、コード生成部305は、上述のように構築したデータベースに対するアクセスを行うデータベースアクセスプログラムを、データ項目・型テーブル308より読み出したデータ項目およびその型をもとに生成する(S602)。この場合、コード生成部305は、例えば、データ項目に対応する入力データを要求処理プログラム(後述)より受け取るコード、入力データをデータベースに登録するための命令文を生成するコード、命令文をデータベースに実行させ、その実行結果を要求処理プログラムへ返すコードを、データベースアクセスプログラムとして生成する。いずれにしても、コード生成部305は、こうしたプログラムを生成するため、所定の構造を備えるプログラムのひな形を保持しており、このひな形における所定箇所に上述のデータ項目と型の情報を設定し、プログラムを生成する。
Next, the
次に、コード生成部305は、ウェブブラウザからの入力データの受信とウェブブラウザへの応答の返信を行う要求処理プログラムを、データ項目・型テーブル308より読み出したデータ項目およびその型をもとに生成する(S603)。例えば、コード生成部305は、ウェブブラウザからの入力データを受け取るコード、データベースアクセスプログラムを起動し入力データを受け渡して処理を実行させるコード、データベースアクセスプログラムの実行結果を受け取り、それをウェブブラウザに返信するコードを、要求処理プログラムとして生成する。この場合もコード生成部305は、こうしたコードを生成するため、所定の構造を備えるコードのひな形を保持しており、このひな形における所定箇所に上述のデータ項目と型の情報を設定し、上述のコードを生成する。
Next, the
そしてコード生成部305は、画面コード生成プログラム生成処理を実行する(S604)。画面コード生成プログラム生成処理S604では、ウェブブラウザの画面の表示や動作を制御する画面コード生成プログラムを、データ項目・型テーブル308より読み出したデータ項目およびその型をもとに生成する。例えば、コード生成部305は、図19に示すフローチャートにしたがって画面コード生成プログラムを生成する。この処理の詳細については後述する。
Then, the
最後に、コード生成部305は上述までのステップで生成したコードを記憶部307に格納し(S605)、コード生成処理S105を終了する。
Finally, the
図19は、第1の実施形態におけるプログラム生成方法の処理手順例7を示すフロー図であり、具体的には、コード生成部305の実施する画面コード生成プログラム生成処理S604の一例を示すフローチャートである。本処理は、例えば、図2のウェブブラウザ画面203を生成するコードを生成する処理である。
FIG. 19 is a flowchart showing a processing procedure example 7 of the program generation method according to the first embodiment. Specifically, the flowchart shows an example of the screen code generation program generation processing S604 performed by the
まず、コード生成部305は、画面コード生成プログラムとなるファイルを生成する(S701)。この状態では、画面コード生成プログラムは、白紙の画面を表現する画面コードを生成する機能しか持っていない。
First, the
次に、コード生成部305は、上述のステップS603までで処理対象としていたデータ項目のデータ項目名と、当該データ項目に対応するデータ入力エリアとを画面に表示するコードを生成し、上述のファイルに追加する(S702)。また、コード生成部305は、さらに「登録」、「中止」ボタンを画面に表示するコードを生成し、ファイルに追加する(S703)。いずれの画面表示用のコードも、コード生成部305が予め保持するコードのひな形に、上述のデータ項目に関する各種情報を設定して生成できる。こうした処理により、図2のウェブブラウザ画面203のような外観の画面データが生成される。
Next, the
そして、コード生成部305は、画面において「登録」ボタン押下操作時にデータ入力エリアに入力された情報を、要求処理プログラムへ送信するコードを生成し、上述のファイルに追加する(S704)。コード生成部305は、さらに「中止」ボタン押下操作時に画面を閉じるコードを生成し、上述のファイルに追加する(S705)。これにより、図2のウェブブラウザ画面203における各ボタン(「登録」、「中止」の各ボタン)に対応する機能が追加される。こうして上述のファイルすなわち画面コード生成プログラムが生成される。
Then, the
−−−第2の実施形態−−−
続いて第2の実施形態について説明する。この実施形態では、上述したデータ項目判定処理S102において、最下位ラベルの並び方向を判定する最下位ラベル並び方向判定、および最下位ラベルを判定する特定方向最下位ラベル判定を実施する場合の例について述べる。これらの判定では、スプレッドシート103の行、列ごとの非空白セルの連なりの個数カウントに対して所定の条件を評価し、この評価結果に応じて、判定対象をデータ項目・型判定部304がそのまま判定するか、あるいは、画面制御部306を介して表示装置302に判定の候補を表示し、入力装置301に対する集約主体等のユーザの操作内容を受け付け、その操作に応じて判定するか、を決定する。
--- Second Embodiment ---
Next, a second embodiment will be described. In this embodiment, in the above-described data item determination processing S102, an example in which the lowest label alignment direction determination for determining the alignment direction of the lowest label and the specific direction lowest label determination for determining the lowest label are performed. State. In these determinations, a predetermined condition is evaluated for the number of consecutive non-blank cells for each row and column of the
ここで、画面制御部306を介して、表示装置302に、ある判定に関する情報を表示し、入力装置301に対する集約主体等のユーザの操作内容を受け付け、その操作に応じて判定を実施する一連の処理のことを、「対話」と呼ぶ。
Here, a series of information about a certain determination is displayed on the
図20は、第2の実施形態におけるプログラム生成方法の処理手順例1を示すフロー図であり、具体的には、データ項目・型判定部304の実施するデータ項目判定処理S102の一例を示すフローチャートである。
FIG. 20 is a flowchart illustrating a processing procedure example 1 of the program generation method according to the second embodiment. Specifically, the flowchart illustrates an example of the data item determination process S102 performed by the data item /
この場合、データ項目・型判定部304は、スプレッドシート103を読み取り、第1の実施形態と同様に、行や列ごとの非空白セルの連なりの個数をカウントする(S801)。
In this case, the data item /
次にデータ項目・型判定部304は、最下位ラベル並び方向判定を実施する(S802)。最下位ラベル並び方向判定S802において、データ項目・型判定部304は、カウント最大の行、カウント最大の列の2つのうち、カウントが小さくないほうをM、他方をmとし(カウント最大の行および列が複数存在する場合はカウント最大の行および列のいずれをMまたはmとしてもよい)、パラメータKを用い、以下の数式で表される条件(以下、条件K)を評価する。
N(M)<N(m)×K−−−(式1)
Next, the data item /
N (M) <N (m) × K −−− (Formula 1)
ここで、パラメータKはあらかじめ定められた、1より大きい実数とする。式1が示す条件Kが成立する場合、データ項目・型判定部304は、並び方向に関するユーザとの「対話」を「要」と判定する(S803:YES)。一方、上述の条件Kが成立しない場合、データ項目・型判定部304は並び方向対話を「不要」とする(S803:NO)。
Here, the parameter K is a predetermined real number greater than 1. When the condition K shown in
データ項目・型判定部304は、並び方向対話が「要」である場合(S803:YES)、画面制御部306を介し、表示装置302、入力装置301と情報を受け渡し、図21Bのような画面2100によって並び方向に対するユーザとの対話を実施する(S804)。
When the arrangement direction dialogue is “necessary” (S803: YES), the data item /
データ項目・型判定部304は、この画面2100における並び方向対話では、入力装置301に対する集約主体等のユーザの操作内容に応じ、最下位ラベルの並び方向(行または列)の選択、あるいは、データ項目手動選択の実行の選択、を受け付ける。
In the arrangement direction dialogue on the
ここでデータ項目・型判定部304は、画面2100を介した並び方向対話で、データ項目手動選択がユーザにより選択されたか否かを判定する(S805)。
Here, the data item /
他方、並び方向対話が「不要」である場合(S803:NO)、データ項目・型判定部304は、最下位のラベル並び方向を、上述した「M」の方向に決定する(S806)。すなわち、「M」がいずれかの行の場合、最下位ラベルの並び方向を行方向とし、「M」がいずれかの列の場合、最下位ラベルの並び方向を列方向とする。そして、S807に処理を進める。
On the other hand, when the arrangement direction dialogue is “unnecessary” (S803: NO), the data item /
最下位ラベルの並び方向がS806によって決定、あるいは、並び方向対話による選択によって決定される(S805:NO)と、次にデータ項目・型判定部304は、特定方向最下位ラベル判定を実施する(S807)。この特定方向最下位ラベル判定S807において、データ項目・型判定部304は、カウントに基づいた行または列のソートを行う。決定された最下位ラベル並び方向が行方向の場合、データ項目・型判定部304は、行をカウントの大きい順,カウントが同じ行については下の行が先になるようにソートする。決定された最下位ラベル並び方向が列方向の場合、データ項目・型判定部304は、列をカウントの大きい順,カウントが同じ列については右の列が先になるようにソートする。そしてデータ項目・型判定部304は、上述したソート順で1番および2番の要素(行または列)をそれぞれ「S1」、「S2」とし、パラメータ「L」を用い、以下の数式で表される条件(以下、条件L)を評価する。
N(S1)<N(S2)×L−−−−(式2)
When the arrangement direction of the lowest label is determined in S806 or is determined by selection by the arrangement direction dialogue (S805: NO), the data item /
N (S1) <N (S2) × L ---- (Formula 2)
ここで、パラメータLはあらかじめ定められた、1より大きい実数とする。式2が示す条件Lが成立する場合、データ項目・型判定部304は、データ項目対話を「要」とする(S808:YES)。一方、式2が示す条件Lが成立しない場合、データ項目・型判定部304はデータ項目対話を「不要」とする(S808:NO)。
Here, the parameter L is a predetermined real number larger than 1. When the condition L indicated by
次にデータ項目・型判定部304は、データ項目対話が「要」である場合(S808:YES)、あるいは並び方向対話でデータ項目手動選択が選択された場合(S805:YES)、画面制御部306を介し表示装置302、入力装置301と情報を受け渡し、図22B、図22C、図22Dのような画面によってデータ項目に対する対話を実施する(S809)。
Next, when the data item dialogue is “necessary” (S808: YES), or when the data item manual selection is selected in the arrangement direction dialogue (S805: YES), the data item /
このデータ項目対話では、データ項目・型判定部304は、スプレッドシート103に含まれるすべての非空白セルの内容を取得し、それらを図22Bのような画面2200で表示装置302に表示する。データ項目・型判定部304は、この画面2200において、ユーザによる、最下位ラベルの選択操作と決定ボタン2201の押下操作を受け付けることによって、選択された最下位ラベルの各々に対する第1上位ラベルの選択画面2300(図22C)を表示装置302に表示する。
In this data item dialogue, the data item /
そして、データ項目・型判定部304は、上述した画面2300において、各々の最下位ラベルに対する第1上位ラベルの選択操作と決定ボタン2202の押下操作を受け付けることによって、第1上位ラベルが選択されたデータ項目の各々に対する第2上位ラベルの選択画面2400(図22D)を表示装置302に表示する。
Then, the data item /
以下、データ項目・型判定部304は、すべてのデータ項目に対して上位ラベルの選択が「なし」になるまで同様に、画面表示と入力操作の受け付けを実施する。すべてのデータ項目に対して上位ラベルの選択が終わったところで、データ項目・型判定部304は、階層構造まで含めたデータ項目を決定し、データ項目判定処理S102を終了する。
Thereafter, the data item /
一方、データ項目対話が「不要」である場合(S808:NO)、データ項目・型判定部304は、前述の「S1」に含まれる最大連続非空白セルを参照し、その記入内容を最下位ラベルとし(S810)、階層構造判定処理を実施する(S811)。本実施形態における階層構造判定処理S811は、第1の実施形態の階層構造判定処理S203と同様の処理である。階層構造判定処理S811の終了により、データ項目・型判定部304は階層構造まで含めたデータ項目を決定し、データ項目判定処理S102を終了する。
On the other hand, when the data item dialogue is “unnecessary” (S808: NO), the data item /
図21Aは、最下位ラベル並び方向判定処理の概念例を示す図であり、具体的には、データ項目・型判定部304が読み込んだスプレッドシート103のデータを示す概念図であって、最下位ラベル並び方向判定S802および並び方向対話S804の一例を説明する概念図である。本例では、最下位ラベル並び方向判定S802に関するパラメータKを「2」として説明する。また、スプレッドシート103の行および列の端の矢印の先に、カウントを表す数値を示している。
FIG. 21A is a diagram showing a conceptual example of the lowest label alignment direction determination process, specifically, a conceptual diagram showing the data of the
この場合、最下位ラベル並び方向判定S802では、カウント最大の行、カウント最大の列の2つのうち、カウントが小さくないほうをM、他方をmとするので、本例では、Mは「R4」、mは「C1」となる(mはC2としても同じ)。 In this case, in the lowest label arrangement direction determination S802, of the two rows of the maximum count and the maximum count column, M is the smaller count and the other is m. In this example, M is “R4”. , M becomes “C1” (m is the same as C2).
また、パラメータKを「2」とすると、条件Kの左辺はN(M)=N(R4)=6であり、右辺はN(m)×K=N(C1)×K=4×2=8となる。従って、条件Kの(左辺)<(右辺)を満たすから、並び方向対話が「要」となる。データ項目・型判定部304は、上述したように、図21Bのような画面2100によって並び方向対話S804を実施する。
If the parameter K is “2”, the left side of the condition K is N (M) = N (R4) = 6, and the right side is N (m) × K = N (C1) × K = 4 × 2 = 8 Therefore, since the condition K (left side) <(right side) is satisfied, the arrangement direction dialogue becomes “necessary”. As described above, the data item /
図22Aは、本発明の第2実施形態の、特定方向最下位ラベル判定S807およびデータ項目対話S809の一例を説明する概念図である。本例では、特定方向最下位ラベル判定S807に関するパラメータLを「2」として説明する。 FIG. 22A is a conceptual diagram illustrating an example of the specific direction lowest label determination S807 and the data item dialog S809 according to the second embodiment of this invention. In this example, the parameter L related to the specific direction lowest label determination S807 will be described as “2”.
図22Aは、データ項目・型判定部304が読み込んだスプレッドシートデータを示す概念図である。スプレッドシート103の行および列の端の矢印の先に、カウントを表す数値を示す。本例のスプレッドシート103では最下位ラベル並び方向判定S802で、K≦4/3の場合、条件Lの判定において並び方向対話「不要」となり、最下位ラベルの並び方向を行方向と判定する。K>4/3の場合も、並び方向対話S804の結果、最下位ラベルの並び方向が行方向とされたものとする。
FIG. 22A is a conceptual diagram showing spreadsheet data read by the data item /
特定方向最下位ラベル判定S807では、行をカウントの大きい順,カウントが同じ行については下の行が先になるようにソートするので、本例では、ソート結果は{R3,R5,R2,…}となる。ソート順で1番、2番の行をそれぞれ「S1」、「S2」とするので、本例では、「S1」は「R3」、「S2」は「R5」となる。 In the specific direction lowest label determination S807, the rows are sorted in the descending order of the counts, and the rows with the same count are sorted so that the lower row comes first. In this example, the sorting result is {R3, R5, R2,. }. Since the first and second rows in the sort order are “S1” and “S2”, respectively, “S1” is “R3” and “S2” is “R5” in this example.
パラメータLを「2」とすると、条件Lの左辺はN(S1)=N(R3)=4であり、右辺はN(S2)×L=N(R5)×L=3×2=6となる。従って、条件Lの(左辺)<(右辺)を満たすため、データ項目対話が「要」となる。データ項目・型判定部304は、上述したように、図22B、図22C、図22Dのような画面によってデータ項目対話S809を実施する。
When the parameter L is “2”, the left side of the condition L is N (S1) = N (R3) = 4, and the right side is N (S2) × L = N (R5) × L = 3 × 2 = 6. Become. Therefore, since the condition L (left side) <(right side) is satisfied, the data item dialogue becomes “necessary”. As described above, the data item /
−−−第3の実施形態−−−
次に第3の実施形態について説明する。本実施形態では、第2の実施形態と同様に、データ項目判定処理S102において、2つの判定(最下位ラベル並び方向判定S802、特定方向最下位ラベル判定S807)と、判定結果に応じて2つの対話(並び方向対話S804、データ項目対話S809)を実施する。第2の実施形態との違いは、特定方向最下位ラベル判定S807において評価する条件Lの内容である。
--- Third Embodiment ---
Next, a third embodiment will be described. In the present embodiment, as in the second embodiment, in the data item determination process S102, two determinations (lowest label arrangement direction determination S802, specific direction lowest label determination S807) and two according to the determination result are performed. Dialogues (alignment direction dialogue S804, data item dialogue S809) are performed. The difference from the second embodiment is the content of the condition L evaluated in the specific direction lowest label determination S807.
図23Aは、本発明の第3実施形態の、特定方向最下位ラベル判定S807の一例を説明する概念図である。本実施形態における特定方向最下位ラベル判定S807で、データ項目・型判定部304は、カウントに基づいて行または列のソートを行い、ソート順で1番、2番の要素(最下位ラベル並び方向が行方向の場合は行、最下位ラベル並び方向が列方向の場合は列)をそれぞれS1、S2とする点は第2の実施形態と同様である。
FIG. 23A is a conceptual diagram illustrating an example of specific direction lowest label determination S807 according to the third embodiment of this invention. In the specific direction lowest label determination S807 in this embodiment, the data item /
一方、本実施形態では、まずパラメータL1を用い、以下の数式で表される条件L1を評価する。
N(S1)<N(S2)×L1−−−(式3)
On the other hand, in the present embodiment, first, the parameter L1 is used to evaluate the condition L1 expressed by the following formula.
N (S1) <N (S2) × L1 --- (Formula 3)
ここで、パラメータL1はあらかじめ定められた、1より大きい実数とする。さらに本実施例において、データ項目・型判定部304は、条件L2として、最下位ラベル並び方向が行方向の場合「S2がS1に上から隣接しない」、最下位ラベル並び方向が列方向の場合「S2がS1に左から隣接しない」を評価する。
Here, the parameter L1 is a predetermined real number larger than 1. Further, in this embodiment, the data item /
また、上述した条件Lを「条件L1かつ条件L2」とおき、データ項目・型判定部304はデータ項目対話の要、不要を判定する。すなわち、条件L1および条件L2の成立、不成立に応じて、データ項目・型判定部304は、図23Aの表に示すようにデータ項目対話の要、不要を判定する。
The above-mentioned condition L is set as “condition L1 and condition L2,” and the data item /
図23Bは、本発明の第3実施形態の、データ項目・型判定部304が読み込んだスプレッドシート103のデータを示す概念図である。スプレッドシート103の行および列の端の矢印の先に、カウントを表す数値を示す。本例では、特定方向最下位ラベル判定S807に関するパラメータL1を「2」として説明する。
FIG. 23B is a conceptual diagram illustrating data of the
本例のスプレッドシート103では最下位ラベル並び方向判定S802で、K≦5/2の場合、条件Kの判定において並び方向対話「不要」となり、最下位ラベルの並び方向を行方向と判定する。K>5/2の場合も、並び方向対話S804の結果、最下位ラベルの並び方向が行方向とされたものとする。
In the
特定方向最下位ラベル判定S807では、行をカウントの大きい順,カウントが同じ行については下の行が先になるようにソートするので、本例では、ソート結果は{R3,R2,R5,…}となる。ソート順で1番、2番の行をそれぞれS1、S2とするので、本例では、S1はR3、S2はR2となる。 In the specific direction lowest label determination S807, the rows are sorted in the descending order of counts, and the rows with the same count are sorted so that the lower row comes first. In this example, the sorting result is {R3, R2, R5,. }. Since the first and second rows in the sort order are S1 and S2, respectively, S1 is R3 and S2 is R2 in this example.
パラメータL1を2とすると、条件L1の左辺はN(S1)=N(R3)=5であり、右辺はN(S2)×L1=N(R2)×L1=3×2=6となる。従って、条件L1の(左辺)<(右辺)は成立する。 When the parameter L1 is 2, the left side of the condition L1 is N (S1) = N (R3) = 5, and the right side is N (S2) × L1 = N (R2) × L1 = 3 × 2 = 6. Therefore, (left side) <(right side) of the condition L1 is satisfied.
ところが、条件L2「S2がS1に上から隣接しない」は、S2であるR2がS1であるR3の上から隣接しているため、不成立である。従って、図23Aの表より、データ項目対話「不要」となり、S810により、R3に含まれる最大連続非空白セルの記入内容、すなわち「A」、「B」、「C」、「D」、「E」を最下位ラベルとする。 However, the condition L2 “S2 is not adjacent to S1 from above” is not satisfied because R2 that is S2 is adjacent to R3 that is S1. Accordingly, the data item dialog “unnecessary” is obtained from the table of FIG. 23A, and the entry contents of the maximum continuous non-blank cell included in R3, that is, “A”, “B”, “C”, “D”, “ Let “E” be the lowest label.
本実施形態は、特定方向最下位ラベル判定S807の条件において、第1上位ラベルの個数が最下位ラベルの個数と大差ないくらい多くなる場合があることを鑑みて設定された、条件L2に特徴を持つ。条件L2を設定することによって、集約主体等のユーザが画面制御部306を介して実施するデータ項目対話が不必要に発生することを抑える。
This embodiment is characterized by the condition L2, which is set in view of the fact that the number of first upper labels may be as large as the number of the lowest labels in the condition of the specific direction lowest label determination S807. Have. By setting the condition L2, it is possible to suppress unnecessary occurrence of data item dialogue performed by a user such as an aggregation entity via the
−−−第4の実施形態−−−
次に第4の実施形態について説明する。本実施形態では、データ型判定処理S103において、すでに図12Aに示したラベル・型対応リスト313や、図12Bに示した文字・型対応リスト314を利用してデータ項目に対応する型を判定できない場合、第1の実施形態のように、あらかじめ定めたデフォルトの型に決定するのではなく、型対話を実施することによりデータ型を判定する。
--- Fourth Embodiment ---
Next, a fourth embodiment will be described. In this embodiment, in the data type determination process S103, the type corresponding to the data item cannot be determined using the label /
図24は、第4の実施形態におけるプログラム生成方法の処理手順例1を示すフロー図であり、具体的には、データ項目・型判定部304の実施するデータ型判定処理S103の一例を示すフローチャートである。この場合、最下位ラベルがラベル・型対応リスト313に掲載されているか否かの判定(S902)や、最下位ラベルと文字・型対応リスト314によって型を決定できるか否かの判定(S904)については、本実施形態は、第1実施形態と同様である。
FIG. 24 is a flowchart showing a processing procedure example 1 of the program generation method in the fourth embodiment, and specifically, a flowchart showing an example of the data type determination processing S103 performed by the data item /
本実施形態では、第1の実施形態のデータ型判定処理S103のS405に代わり、データ項目・型判定部304はS905を実施する。S905は、2つのリストによって型が判定できなかった場合に実行されるステップであり、データ項目・型判定部304は、判定対象のデータ項目を型不定データ項目リストに登録する。
In the present embodiment, the data item /
また、データ項目・型判定部304は、すべてのデータ項目について、データ型を決定する、或いは、型不定データ項目リストへ登録する、のいずれかを実施した後(S906:NO)に、型不定データ項目リストに登録されたデータ項目があるか否を判定する(S908)。
The data item /
型不定データ項目リストに登録されたデータ項目がある場合(S908:YES)、データ項目・型判定部304は、画面制御部306を介し表示装置302、入力装置301と情報を受け渡し、図25のような画面2500によって、型不定データ項目の型に対する対話(型対話)を実施する(S909)。型対話において、データ項目・型判定部304は、入力装置301に対する集約主体等のユーザの操作内容に応じ、型不定データ項目リストに登録されたデータ項目の型の選択を受け付ける。そして、データ項目・型判定部304は、受け付けたデータ項目の最下位ラベルと型の対応を、ラベル・型対応リスト313に追記し(S910)、型判定処理S103を終了する。一方、型不定データ項目リストに登録されたデータ項目がない場合(S908:NO)、データ項目・型判定部304は型判定処理S103を終了する。
When there is a data item registered in the undefined type data item list (S908: YES), the data item /
以上、本発明を実施するための最良の形態などについて具体的に説明したが、本発明はこれに限定されるものではなく、その要旨を逸脱しない範囲で種々変更可能である。 Although the best mode for carrying out the present invention has been specifically described above, the present invention is not limited to this, and various modifications can be made without departing from the scope of the invention.
こうした本実施形態によれば、スプレッドシートを用いた業務をウェブアプリケーションに移行する際の、ユーザ作業量を効果的に抑制し、ウェブアプリケーションプログラムのコードを効率的に生成できる。 According to the present embodiment, it is possible to effectively suppress the amount of user work and efficiently generate the code of the web application program when the work using the spreadsheet is transferred to the web application.
本明細書の記載により、少なくとも次のことが明らかにされる。すなわち、本実施形態のプログラム生成システムにおいて、演算部は、第1処理において、スプレッドシートデータから前記データ項目の配置を判定するデータ項目判定処理と、前記データ項目の値のデータ型を判定するデータ型判定処理とを実行するものであり、データ項目判定処理は、各データ項目の配置に基づいて、1または複数のデータ項目とこれに隣接し包含する上位のデータ項目との関係で規定されるデータ項目間の階層構造を特定する階層構造判定処理と、階層構造のうち最下位に位置するデータ項目群を、該当セルの連続数の大きさと階層構造中での位置が所定条件を満たすものとして判定し、該当データ項目群を最下位ラベルとして特定する最下位ラベル判定処理とを含むものである、としてもよい。 At least the following will be clarified by the description of the present specification. That is, in the program generation system of the present embodiment, in the first process, the calculation unit is a data item determination process that determines the arrangement of the data items from the spreadsheet data, and data that determines the data type of the value of the data item The data item determination process is defined by the relationship between one or a plurality of data items and an upper data item adjacent to and including the data item determination process based on the arrangement of the data items. Hierarchical structure determination processing that identifies the hierarchical structure between data items, and the data item group positioned at the bottom of the hierarchical structure, assuming that the number of consecutive cells in the hierarchy and the position in the hierarchical structure satisfy a predetermined condition And a lowest label determination process for determining and identifying the corresponding data item group as the lowest label.
また、本実施形態のプログラム生成システムにおいて、演算部は、最下位ラベル判定処理において、スプレッドシートデータの各行または各列において、連続する前記非空白セルの個数の最大値を当該行または列のカウントとして特定し、スプレッドシートデータに含まれるすべての行および列の中で、カウントが最大である行または列を特定し、当該特定した行または列において最も連続した非空白セルの記入内容を最下位ラベルと判定するものである、としてもよい。 In the program generation system of the present embodiment, in the lowest label determination process, the calculation unit counts the maximum number of consecutive non-blank cells in each row or each column of spreadsheet data. Identify the row or column with the highest count among all the rows and columns contained in the spreadsheet data, and fill in the most consecutive non-blank cell entry in the identified row or column It may be determined as a label.
また、本実施形態のプログラム生成システムにおいて、演算部は、階層構造判定処理において、最下位ラベルの並び方向が行方向である場合、最下位ラベルの各々について、スプレッドシートデータ上において、該当最下位ラベルのセルから上方向に隣接するセルを参照し、当該隣接セルが空白セルでない場合、当該隣接セルの記入内容を上位階層のラベルと仮判定し、最下位ラベルと当該仮判定した上位階層のラベルの情報を階層順に連結して生成した項目名と、隣接セルの行位置とを、記憶部の階層構造判定表へ記憶することを繰り返し、最下位ラベルの全てについて、階層構造判定表への項目名と行位置の記憶が終了した後に、階層構造判定表において、全ての最下位ラベルに共通する行位置のうち最も上の行位置に対応する項目名を特定し、当該項目名を最下位ラベルごとに階層構造の情報として記憶部に格納し、最下位ラベルの並び方向が列方向である場合に、最下位ラベルの各々について、スプレッドシートデータ上において、該当最下位ラベルのセルから左方向に隣接するセルを参照し、当該隣接セルが空白セルでない場合、当該隣接セルの記入内容を上位階層のラベルと仮判定し、最下位ラベルと当該仮判定した上位階層のラベルの情報を階層順に連結して生成した項目名と、隣接セルの列位置とを、記憶部の階層構造判定表へ記憶することを繰り返し、最下位ラベルの全てについて、階層構造判定表への項目名と列位置の記憶が終了した後に、階層構造判定表において、全ての最下位ラベルに共通する列位置のうち最も左の列位置に対応する項目名を特定し、当該項目名を最下位ラベルごとに階層構造の情報として記憶部に格納するものである、としてもよい。 In the program generation system according to the present embodiment, in the hierarchical structure determination process, when the arrangement direction of the lowest label is the row direction, the arithmetic unit determines the corresponding lowest order on the spreadsheet data for each of the lowest labels. When a cell adjacent to the label cell is referred to in the upward direction and the adjacent cell is not a blank cell, the entry content of the adjacent cell is provisionally determined to be an upper layer label, and the lowest label and the temporary layer It repeats storing the item name generated by concatenating the label information in the hierarchical order and the row position of the adjacent cell in the hierarchical structure determination table of the storage unit, and all the lowest labels are stored in the hierarchical structure determination table. After storing the item name and line position, the item name corresponding to the top line position among the line positions common to all the lowest labels in the hierarchical structure judgment table is displayed. And the item name is stored in the storage unit as hierarchical structure information for each lowest label, and when the arrangement direction of the lowest label is the column direction, for each of the lowest labels on the spreadsheet data, Referring to a cell adjacent to the left from the cell of the lowest label, if the adjacent cell is not a blank cell, the entry content of the adjacent cell is provisionally determined to be a higher-level label, and the lowest label is temporarily determined Repeatedly stores the item names generated by concatenating the information of the higher-level labels in the hierarchical order and the column positions of adjacent cells in the hierarchical structure determination table of the storage unit, and determines the hierarchical structure for all the lowest labels. After storing the item names and column positions in the table, specify the item name corresponding to the leftmost column position among the column positions common to all the lowest labels in the hierarchical structure determination table. It is intended to be stored in the storage unit an item name for each minimum label as information of the hierarchical structure or a.
また、本実施形態のプログラム生成システムにおいて、記憶部は、最下位ラベルの値とデータ型との対応関係を記述したラベル・型対応リストと、最下位ラベルの末尾文字とデータ型との対応関係を記述した文字・型対応リストとを記憶しており、演算部は、データ型判定処理において、データ項目の各々について、該当データ項目が属する階層構造での最下位ラベルの値を、ラベル・型対応リストに照合し、最下位ラベルの値に対応するデータ型を特定できた場合、該当データ型をデータ項目のデータ型と判定し、最下位ラベルの値に対応するデータ型を特定できなかった場合、最下位ラベルを構成する文字列の末尾の一つまたは複数の文字を、文字・型対応リストに照合し、最下位ラベルの末尾文字に対応するデータ型を特定できた場合、該当データ型をデータ項目のデータ型と判定し、最下位ラベルの末尾文字に対応するデータ型を特定できなかった場合、デフォルトのデータ型をデータ項目のデータ型と判定するものである、としてもよい。 In the program generation system of the present embodiment, the storage unit includes a label / type correspondence list describing the correspondence between the value of the lowest label and the data type, and the correspondence between the last character of the lowest label and the data type. In the data type determination process, the calculation unit sets the value of the lowest label in the hierarchical structure to which the data item belongs to the label / type in the data type determination process. If the data type corresponding to the value of the lowest label could be identified by checking the correspondence list, the data type was determined to be the data type of the data item, and the data type corresponding to the value of the lowest label could not be specified. If the data type corresponding to the last character of the lowest label can be identified by matching one or more characters at the end of the character string constituting the lowest label against the character / type correspondence list If the corresponding data type is determined as the data type of the data item and the data type corresponding to the last character of the lowest label cannot be specified, the default data type is determined as the data type of the data item. Good.
また、本実施形態のプログラム生成システムにおいて、演算部は、最下位ラベル判定処理において、スプレッドシートデータの各行または各列において、連続する非空白セルの個数の最大値を当該行または列のカウントとして特定し、スプレッドシートデータに含まれるすべての行の中でカウントが最大の行のカウントと、スプレッドシートデータに含まれるすべての列の中でカウントが最大の列のカウントとを比較し、両者のうち小さくないカウントが、他方のカウントに1より大きい値を持つ第1の実定数を乗じた値よりも小さい場合、入出力部に、最下位ラベルの並び方向に関する確認要求を出力し、この確認要求に応じたユーザ入力を入出力部で受け付け、当該ユーザ入力に応じて最下位ラベルの並び方向を特定し、小さくないカウントが、他方のカウントに1より大きい値を持つ第1の実定数を乗じた値よりも小さくない場合、スプレッドシートデータに含まれるすべての行の中でカウントが最大の行のカウントと、スプレッドシートデータに含まれるすべての列の中でカウントが最大の列のカウントのうち、小さくないほうの方向を最下位ラベルの並び方向と判定する、最下位ラベル並び方向判定処理を実行するものであるとしてもよい。 In the program generation system of the present embodiment, in the lowest label determination process, the arithmetic unit uses the maximum value of the number of consecutive non-blank cells in each row or each column of the spreadsheet data as the count of that row or column. Identify and compare the count of the row with the highest count among all the rows in the spreadsheet data with the count of the column with the highest count among all the columns in the spreadsheet data, If the non-small count is smaller than the value obtained by multiplying the other count by the first real constant having a value greater than 1, a confirmation request regarding the arrangement direction of the lowest label is output to the input / output unit. User input in response to a request is accepted by the input / output unit, and the direction of the lowest label is specified according to the user input. Is not less than the other count multiplied by the first real constant with a value greater than 1, the count of the row with the largest count among all the rows in the spreadsheet data and the spread The lowest label arrangement direction determination process is executed for determining the direction in which the smallest count of all the columns included in the sheet data is counted as the lowest label arrangement direction. It is good.
また、本実施形態のプログラム生成システムにおいて、演算部は、最下位ラベル判定処理において、最下位ラベル並び方向判定処理と、特定方向最下位ラベル判定処理とを実行するものであり、特定方向最下位ラベル判定処理は、最下位ラベル並び方向判定処理で判定した最下位ラベル並び方向に関して、当該方向が行方向である場合、スプレッドシートデータに含まれるすべての行をカウントの大きい順、または、カウントが同じ行については下の行が先になるようにソートし、当該方向が列方向である場合、スプレッドシートデータに含まれるすべての列をカウントの大きい順、または、カウントが同じ列については右の列が先になるようにソートし、ソート結果の1番目の要素のカウントが、ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さい場合、スプレッドシートデータに含まれる全ての非空白セルの記入内容を、最下位ラベルおよび上位階層のラベルの候補として入出力部に出力し、候補中よりユーザが指定した最下位ラベルおよび上位階層のラベルの情報を入出力部にて受け付け、当該受け付けた情報により最下位ラベルおよび上位階層のラベルを特定し、ソート結果の1番目の要素のカウントが、ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さくない場合、ソート結果の1番目の要素に含まれる最も連続した非空白セルの記入内容を最下位ラベルと判定するものである、としてもよい。 Further, in the program generation system of the present embodiment, the calculation unit executes the lowest label arrangement direction determination process and the specific direction lowest label determination process in the lowest label determination process, and the lowest direction in the specific direction. In the label determination process, regarding the lowest label arrangement direction determined in the lowest label arrangement direction determination process, when the direction is the row direction, all the rows included in the spreadsheet data are sorted in descending order of count or If the same row is sorted so that the lower row is first, and the direction is the column direction, all the columns included in the spreadsheet data are sorted in descending order of the count, or for the column with the same count, the right column Sorting so that the column is first, the count of the first element of the sort result is 1 to the count of the second element of the sort result If the value is smaller than the value multiplied by the second real constant with a larger value, the contents of all non-blank cells included in the spreadsheet data are input to the input / output section as candidates for the lowest label and the higher-order label. The input / output unit receives the information on the lowest label and the higher hierarchy label specified by the user from among the candidates, identifies the lowest label and the higher hierarchy label based on the received information, and outputs the first sort result If the count of the element of is not less than the count of the second element of the sort result multiplied by the second real constant having a value greater than 1, the most consecutive element included in the first element of the sort result The entry content of the non-blank cell may be determined as the lowest label.
また、本実施形態のプログラム生成システムにおいて、記憶部は、最下位ラベルの値とデータ型との対応関係を記述したラベル・型対応リストと、最下位ラベルの末尾文字とデータ型との対応関係を記述した文字・型対応リストとを記憶しており、演算部は、データ型判定処理において、データ項目の各々について、該当データ項目が属する階層構造での最下位ラベルの値を、ラベル・型対応リストに照合し、最下位ラベルの値に対応するデータ型を特定できた場合、該当データ型をデータ項目のデータ型と判定し、最下位ラベルの値に対応するデータ型を特定できなかった場合、最下位ラベルを構成する文字列の末尾の一つまたは複数の文字を、文字・型対応リストに照合し、最下位ラベルの末尾文字に対応するデータ型を特定できた場合、該当データ型をデータ項目のデータ型と判定し、最下位ラベルの末尾文字に対応するデータ型を特定できなかった場合、データ項目とデータ項目のデータ型の候補に関する情報を入出力部に出力し、候補中よりユーザが指定したデータ型の情報を入出力部にて受け付け、当該受け付けた情報により、該当データ型をデータ項目のデータ型と判定するものである、としてもよい。 In the program generation system of the present embodiment, the storage unit includes a label / type correspondence list describing the correspondence between the value of the lowest label and the data type, and the correspondence between the last character of the lowest label and the data type. In the data type determination process, the calculation unit sets the value of the lowest label in the hierarchical structure to which the data item belongs to the label / type in the data type determination process. If the data type corresponding to the value of the lowest label could be identified by checking the correspondence list, the data type was determined to be the data type of the data item, and the data type corresponding to the value of the lowest label could not be specified. If the data type corresponding to the last character of the lowest label can be identified by matching one or more characters at the end of the character string constituting the lowest label against the character / type correspondence list If the data type is determined to be the data type of the data item and the data type corresponding to the last character of the lowest label cannot be specified, information on the data item and the data type candidate of the data item is output to the input / output unit. The information of the data type designated by the user from among the candidates may be received by the input / output unit, and the corresponding data type may be determined as the data type of the data item based on the received information.
また、本実施形態のプログラム生成システムにおいて、演算部は、特定方向最下位ラベル判定処理において、ソート結果の1番目の要素のカウントが、ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さい時、最下位ラベルの並び方向が行方向の場合で、ソート結果の2番目の行がソート結果の1番目の行に上から隣接する場合か、最下位ラベルの並び方向が列方向の場合で、ソート結果の2番目の列がソート結果の1番目の列に左から隣接する場合は、ソート結果の1番目の要素に含まれる最も連続した非空白セルの記入内容を最下位ラベルと判定するものである、としてもよい。 In the program generation system according to the present embodiment, in the specific direction lowest label determination process, the calculation unit sets the count of the first element of the sort result to a value greater than 1 for the count of the second element of the sort result. If the value is smaller than the value multiplied by the second real constant, and if the label direction is the row direction and the second row of the sorting result is adjacent to the first row of the sorting result from above In the case where the arrangement direction of the lowest label is the column direction, and the second column of the sorting result is adjacent to the first column of the sorting result from the left, it is the most consecutive in the first element of the sorting result. The entry content of the non-blank cell may be determined as the lowest label.
103 スプレッドシート
104 データファイル(スプレッドシートデータ)
150 データベース
301 入力装置
302 出力装置
303 プログラム生成システム
304 データ項目・型判定部
305 コード生成部
306 画面制御部
307 記憶部
308 データ項目・型テーブル(テーブル)
309 要求処理プログラムコード
310 データベースアクセスプログラムコード
311 画面コード生成プログラムコード
312 データベース
313 ラベル・型対応リスト
314 文字・型対応リスト
315 階層構造判定表
401 クライアント
403 ウェブブラウザ
402 サーバ
405 要求処理プログラム
406 データベースアクセスプログラム
407 画面コード生成プログラム
408 データベース
502 CPU(演算部)
503 RAM
504 ROM
505 HDD(記憶部)
506 通信I/F
507 入出力c(入出力部)
508 メディア通信I/F
103
150
309 Request
503 RAM
504 ROM
505 HDD (storage unit)
506 Communication I / F
507 Input / output c (input / output unit)
508 Media communication I / F
Claims (10)
スプレッドシートデータを格納した記憶部と、
前記スプレッドシートデータにて非空白セルたるデータ項目を検索し、データ項目の配置と各データ項目の値のデータ型を判定し、前記データ項目の配置とデータ型の情報を、記憶部のテーブルに格納する第1処理と、
前記判定に際し、判定結果の確認用画面を入出力部に出力し、前記判定結果に対するユーザの確認結果を入出力部を介して受け付けて、当該確認結果で前記テーブルを更新する第2処理と、
前記テーブルよりデータ項目の配置およびデータ型の情報を読み出し、前記データ項目とそのデータ型の情報を、記憶部に予め保持するプログラムに設定して、前記データ項目に関して前記データ型での入力を受け付ける入力画面をウェブブラウザに表示させ、ウェブブラウザでの入力データをサーバへ送信させる画面コード生成プログラムを生成する第3処理とを実行する演算部と、
を備えることを特徴とするプログラム生成システム。 An input / output unit responsible for data input / output with external devices;
A storage unit storing spreadsheet data;
Search for data items that are non-blank cells in the spreadsheet data, determine the data item arrangement and the data type of each data item value, and store the data item arrangement and data type information in a table in the storage unit A first process to store;
In the determination, a second process for outputting a determination result confirmation screen to the input / output unit, receiving a user confirmation result for the determination result via the input / output unit, and updating the table with the confirmation result;
Read data item arrangement and data type information from the table, set the data item and its data type information in a program stored in advance in the storage unit, and accept input in the data type for the data item An arithmetic unit that executes a third process for generating a screen code generation program that displays an input screen on a web browser and transmits input data in the web browser to the server;
A program generation system comprising:
前記第1処理において、前記スプレッドシートデータから前記データ項目の配置を判定するデータ項目判定処理と、前記データ項目の値のデータ型を判定するデータ型判定処理とを実行するものであり、
前記データ項目判定処理は、
各データ項目の配置に基づいて、1または複数のデータ項目とこれに隣接し包含する上位のデータ項目との関係で規定されるデータ項目間の階層構造を特定する階層構造判定処理と、
前記階層構造のうち最下位に位置するデータ項目群を、該当セルの連続数の大きさと階層構造中での位置が所定条件を満たすものとして判定し、該当データ項目群を最下位ラベルとして特定する最下位ラベル判定処理とを含むものである、
ことを特徴とする請求項1に記載のプログラム生成システム。 The computing unit is
In the first process, a data item determination process for determining an arrangement of the data item from the spreadsheet data and a data type determination process for determining a data type of the value of the data item are executed.
The data item determination process includes:
A hierarchical structure determination process for specifying a hierarchical structure between data items defined by the relationship between one or more data items and an upper data item adjacent to and including the data items based on the arrangement of each data item;
The data item group positioned at the lowest position in the hierarchical structure is determined as the number of consecutive cells and the position in the hierarchical structure satisfying a predetermined condition, and the corresponding data item group is specified as the lowest label. Including the lowest label determination process,
The program generation system according to claim 1.
前記最下位ラベル判定処理において、
前記スプレッドシートデータの各行または各列において、連続する前記非空白セルの個数の最大値を当該行または列のカウントとして特定し、前記スプレッドシートデータに含まれるすべての行および列の中で、前記カウントが最大である行または列を特定し、当該特定した行または列において最も連続した非空白セルの記入内容を前記最下位ラベルと判定するものである、
ことを特徴とする請求項2に記載のプログラム生成システム。 The computing unit is
In the lowest label determination process,
In each row or column of the spreadsheet data, the maximum value of the number of consecutive non-blank cells is specified as a count of the row or column, and among all the rows and columns included in the spreadsheet data, The row or column having the maximum count is specified, and the entry content of the most continuous non-blank cell in the specified row or column is determined as the lowest label.
The program generation system according to claim 2.
前記階層構造判定処理において、
前記最下位ラベルの並び方向が行方向である場合、前記最下位ラベルの各々について、前記スプレッドシートデータ上において、該当最下位ラベルのセルから上方向に隣接するセルを参照し、当該隣接セルが空白セルでない場合、当該隣接セルの記入内容を上位階層のラベルと仮判定し、前記最下位ラベルと当該仮判定した上位階層のラベルの情報を階層順に連結して生成した項目名と、前記隣接セルの行位置とを、記憶部の階層構造判定表へ記憶することを繰り返し、
前記最下位ラベルの全てについて、前記階層構造判定表への前記項目名と行位置の記憶が終了した後に、前記階層構造判定表において、全ての最下位ラベルに共通する前記行位置のうち最も上の行位置に対応する項目名を特定し、当該項目名を前記最下位ラベルごとに階層構造の情報として記憶部に格納し、
前記最下位ラベルの並び方向が列方向である場合に、前記最下位ラベルの各々について、前記スプレッドシートデータ上において、該当最下位ラベルのセルから左方向に隣接するセルを参照し、当該隣接セルが空白セルでない場合、当該隣接セルの記入内容を上位階層のラベルと仮判定し、前記最下位ラベルと当該仮判定した上位階層のラベルの情報を階層順に連結して生成した項目名と、前記隣接セルの列位置とを、記憶部の階層構造判定表へ記憶することを繰り返し、
前記最下位ラベルの全てについて、前記階層構造判定表への前記項目名と列位置の記憶が終了した後に、前記階層構造判定表において、全ての最下位ラベルに共通する前記列位置のうち最も左の列位置に対応する項目名を特定し、当該項目名を前記最下位ラベルごとに階層構造の情報として記憶部に格納するものである、
ことを特徴とする請求項2に記載のプログラム生成システム。 The computing unit is
In the hierarchical structure determination process,
When the arrangement direction of the lowest label is a row direction, for each of the lowest labels, on the spreadsheet data, refer to a cell adjacent upward from the cell of the lowest label, and the adjacent cell is If it is not a blank cell, the entry content of the adjacent cell is provisionally determined as an upper layer label, and the item name generated by concatenating the information of the lowermost label and the label of the upper layer determined at the temporary determination in hierarchical order, and the adjacent Repeatedly storing the row position of the cell in the hierarchical structure determination table of the storage unit;
For all of the lowest labels, after the storage of the item names and row positions in the hierarchical structure determination table is completed, in the hierarchical structure determination table, the highest of the row positions common to all the lowest labels. The item name corresponding to the line position of the item is identified, and the item name is stored in the storage unit as hierarchical structure information for each lowest label,
When the arrangement direction of the lowest label is a column direction, for each of the lowest labels, on the spreadsheet data, a cell adjacent to the left from the cell of the lowest label is referred to, and the adjacent cell Is not a blank cell, the entry content of the adjacent cell is tentatively determined as an upper layer label, and the item name generated by concatenating the lowest label and the information of the tentatively determined upper layer label in hierarchical order, and Repeatedly storing the column position of the adjacent cell in the hierarchical structure determination table of the storage unit;
After the storage of the item name and column position in the hierarchical structure determination table for all the lowest labels, the leftmost column position common to all the lowest labels in the hierarchical structure determination table The item name corresponding to the column position is specified, and the item name is stored in the storage unit as hierarchical structure information for each lowest label.
The program generation system according to claim 2.
前記最下位ラベルの値とデータ型との対応関係を記述したラベル・型対応リストと、
前記最下位ラベルの末尾文字とデータ型との対応関係を記述した文字・型対応リストとを記憶しており、
前記演算部は、
前記データ型判定処理において、
前記データ項目の各々について、該当データ項目が属する階層構造での最下位ラベルの値を、前記ラベル・型対応リストに照合し、前記最下位ラベルの値に対応するデータ型を特定できた場合、該当データ型を前記データ項目のデータ型と判定し、前記最下位ラベルの値に対応するデータ型を特定できなかった場合、前記最下位ラベルを構成する文字列の末尾の一つまたは複数の文字を、前記文字・型対応リストに照合し、前記最下位ラベルの末尾文字に対応するデータ型を特定できた場合、該当データ型を前記データ項目のデータ型と判定し、前記最下位ラベルの末尾文字に対応するデータ型を特定できなかった場合、デフォルトのデータ型を前記データ項目のデータ型と判定するものである、
ことを特徴とする請求項2に記載のプログラム生成システム。 The storage unit
A label / type correspondence list describing the correspondence between the value of the lowest label and the data type;
Storing a character / type correspondence list describing the correspondence between the last character of the lowest label and the data type;
The computing unit is
In the data type determination process,
For each of the data items, when the value of the lowest label in the hierarchical structure to which the corresponding data item belongs is collated with the label / type correspondence list, and the data type corresponding to the value of the lowest label can be identified, If the data type is determined to be the data type of the data item and the data type corresponding to the value of the lowest label cannot be specified, one or more characters at the end of the character string constituting the lowest label Is matched with the character / type correspondence list, and if the data type corresponding to the last character of the lowest label is identified, the corresponding data type is determined as the data type of the data item, and the end of the lowest label is determined. When the data type corresponding to the character cannot be specified, the default data type is determined as the data type of the data item.
The program generation system according to claim 2.
前記最下位ラベル判定処理において、
前記スプレッドシートデータの各行または各列において、連続する前記非空白セルの個数の最大値を当該行または列のカウントとして特定し、前記スプレッドシートデータに含まれるすべての行の中でカウントが最大の行のカウントと、前記スプレッドシートデータに含まれるすべての列の中でカウントが最大の列のカウントとを比較し、両者のうち小さくないカウントが、他方のカウントに1より大きい値を持つ第1の実定数を乗じた値よりも小さい場合、前記入出力部に、最下位ラベルの並び方向に関する確認要求を出力し、この確認要求に応じたユーザ入力を前記入出力部で受け付け、当該ユーザ入力に応じて最下位ラベルの並び方向を特定し、前記小さくないカウントが、他方のカウントに1より大きい値を持つ第1の実定数を乗じた値よりも小さくない場合、前記スプレッドシートデータに含まれるすべての行の中でカウントが最大の行のカウントと、前記スプレッドシートデータに含まれるすべての列の中でカウントが最大の列のカウントのうち、小さくないほうの方向を最下位ラベルの並び方向と判定する、最下位ラベル並び方向判定処理を実行するものである、
ことを特徴とする請求項2に記載のプログラム生成システム。 The computing unit is
In the lowest label determination process,
In each row or column of the spreadsheet data, the maximum value of the number of consecutive non-blank cells is specified as the count of the row or column, and the count is the largest among all the rows included in the spreadsheet data. First, the row count is compared with the count of the column having the maximum count among all the columns included in the spreadsheet data, and the count that is not less than the first count has a value greater than 1 in the other count. If the value is smaller than the value multiplied by the real constant, a confirmation request regarding the arrangement direction of the lowest label is output to the input / output unit, the user input corresponding to the confirmation request is received by the input / output unit, and the user input The direction of the lowest label is specified according to the above, and the non-small count is multiplied by a first real constant having a value greater than 1 for the other count. If not less than the value, the count of the row with the highest count among all the rows included in the spreadsheet data and the count of the column with the highest count among all the columns included in the spreadsheet data Among these, the direction which is not smaller is determined as the arrangement direction of the lowest label, and the lowest label arrangement direction determination process is executed.
The program generation system according to claim 2.
前記最下位ラベル判定処理において、最下位ラベル並び方向判定処理と、特定方向最下位ラベル判定処理とを実行するものであり、
前記特定方向最下位ラベル判定処理は、
前記最下位ラベル並び方向判定処理で判定した最下位ラベル並び方向に関して、
当該方向が行方向である場合、前記スプレッドシートデータに含まれるすべての行をカウントの大きい順、または、カウントが同じ行については下の行が先になるようにソートし、当該方向が列方向である場合、前記スプレッドシートデータに含まれるすべての列をカウントの大きい順、または、カウントが同じ列については右の列が先になるようにソートし、
前記ソート結果の1番目の要素のカウントが、前記ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さい場合、前記スプレッドシートデータに含まれる全ての非空白セルの記入内容を、最下位ラベルおよび上位階層のラベルの候補として前記入出力部に出力し、前記候補中よりユーザが指定した最下位ラベルおよび上位階層のラベルの情報を前記入出力部にて受け付け、当該受け付けた情報により最下位ラベルおよび上位階層のラベルを特定し、
前記ソート結果の1番目の要素のカウントが、前記ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さくない場合、前記ソート結果の1番目の要素に含まれる最も連続した非空白セルの記入内容を前記最下位ラベルと判定するものである、
ことを特徴とする請求項6に記載のプログラム生成システム。 The computing unit is
In the lowest label determination process, the lowest label arrangement direction determination process and the specific direction lowest label determination process are executed.
The specific direction lowest label determination process includes:
Regarding the lowest label arrangement direction determined in the lowest label arrangement direction determination process,
When the direction is a row direction, all the rows included in the spreadsheet data are sorted in descending order of counts, or for the rows with the same count, the lower row is sorted first, and the direction is the column direction. , Sort all the columns in the spreadsheet data in descending order of count, or for the columns with the same count so that the right column is first,
If the count of the first element of the sort result is smaller than the count of the second element of the sort result multiplied by a second real constant having a value greater than 1, it is included in the spreadsheet data The input contents of all non-blank cells are output to the input / output unit as candidates for the lowest label and the upper layer label, and information on the lowest label and the upper layer label specified by the user from among the candidates is input. Accept at the output unit, specify the lowest label and the upper layer label by the received information,
If the count of the first element of the sort result is not less than the count of the second element of the sort result multiplied by a second real constant having a value greater than 1, the first of the sort result The content of the most continuous non-blank cell included in the element is determined as the lowest label,
The program generation system according to claim 6.
前記最下位ラベルの値とデータ型との対応関係を記述したラベル・型対応リストと、
前記最下位ラベルの末尾文字とデータ型との対応関係を記述した文字・型対応リストとを記憶しており、
前記演算部は、
前記データ型判定処理において、
前記データ項目の各々について、該当データ項目が属する階層構造での最下位ラベルの値を、前記ラベル・型対応リストに照合し、前記最下位ラベルの値に対応するデータ型を特定できた場合、該当データ型を前記データ項目のデータ型と判定し、前記最下位ラベルの値に対応するデータ型を特定できなかった場合、前記最下位ラベルを構成する文字列の末尾の一つまたは複数の文字を、前記文字・型対応リストに照合し、前記最下位ラベルの末尾文字に対応するデータ型を特定できた場合、該当データ型を前記データ項目のデータ型と判定し、前記最下位ラベルの末尾文字に対応するデータ型を特定できなかった場合、前記データ項目と前記データ項目のデータ型の候補に関する情報を前記入出力部に出力し、前記候補中よりユーザが指定したデータ型の情報を前記入出力部にて受け付け、当該受け付けた情報により、該当データ型を前記データ項目のデータ型と判定するものである、
ことを特徴とする請求項2に記載のプログラム生成システム。 The storage unit
A label / type correspondence list describing the correspondence between the value of the lowest label and the data type;
Storing a character / type correspondence list describing the correspondence between the last character of the lowest label and the data type;
The computing unit is
In the data type determination process,
For each of the data items, when the value of the lowest label in the hierarchical structure to which the corresponding data item belongs is collated with the label / type correspondence list, and the data type corresponding to the value of the lowest label can be identified, If the data type is determined to be the data type of the data item and the data type corresponding to the value of the lowest label cannot be specified, one or more characters at the end of the character string constituting the lowest label Is matched with the character / type correspondence list, and if the data type corresponding to the last character of the lowest label is identified, the corresponding data type is determined as the data type of the data item, and the end of the lowest label is determined. When the data type corresponding to the character could not be specified, the information on the data item and the data type candidate of the data item is output to the input / output unit and specified by the user from among the candidates Received in data type information the input-output unit, by the received information is intended to determine the appropriate data types and data types of the data items,
The program generation system according to claim 2.
前記特定方向最下位ラベル判定処理において、
前記ソート結果の1番目の要素のカウントが、前記ソート結果の2番目の要素のカウントに1より大きい値を持つ第2の実定数を乗じた値よりも小さい時、
前記最下位ラベルの並び方向が行方向の場合で、前記ソート結果の2番目の行が前記ソート結果の1番目の行に上から隣接する場合か、前記最下位ラベルの並び方向が列方向の場合で、前記ソート結果の2番目の列が前記ソート結果の1番目の列に左から隣接する場合は、前記ソート結果の1番目の要素に含まれる最も連続した非空白セルの記入内容を前記最下位ラベルと判定するものである、
ことを特徴とする請求項7に記載のプログラム生成システム。 The computing unit is
In the specific direction lowest label determination process,
When the count of the first element of the sorting result is smaller than a value obtained by multiplying the count of the second element of the sorting result by a second real constant having a value greater than 1.
When the arrangement direction of the lowest label is a row direction and the second row of the sorting result is adjacent to the first row of the sorting result from above, or the arrangement direction of the lowest label is a column direction In the case where the second column of the sort result is adjacent to the first column of the sort result from the left, the entry content of the most continuous non-blank cell included in the first element of the sort result is It is determined as the lowest label.
The program generation system according to claim 7.
前記スプレッドシートデータにて非空白セルたるデータ項目を検索し、データ項目の配置と各データ項目の値のデータ型を判定し、前記データ項目の配置とデータ型の情報を、記憶部のテーブルに格納する第1処理と、
前記判定に際し、判定結果の確認用画面を入出力部に出力し、前記判定結果に対するユーザの確認結果を入出力部で受け付けて、当該確認結果で前記テーブルを更新する第2処理と、
前記テーブルよりデータ項目の配置およびデータ型の情報を読み出し、前記データ項目とそのデータ型の情報を、記憶部に予め保持するプログラムに設定して、前記データ項目に関して前記データ型での入力を受け付ける入力画面をウェブブラウザに表示させ、ウェブブラウザでの入力データをサーバへ送信させる画面コード生成プログラムを生成する第3処理と、
を実行することを特徴とするプログラム生成方法。 A computer including an input / output unit that handles data input / output with an external device, and a storage unit that stores spreadsheet data,
Search for data items that are non-blank cells in the spreadsheet data, determine the data item arrangement and the data type of each data item value, and store the data item arrangement and data type information in a table in the storage unit A first process to store;
In the determination, a second process for outputting a determination result confirmation screen to the input / output unit, receiving a user confirmation result for the determination result in the input / output unit, and updating the table with the confirmation result;
Read data item arrangement and data type information from the table, set the data item and its data type information in a program stored in advance in the storage unit, and accept input in the data type for the data item A third process for generating a screen code generation program for displaying an input screen on a web browser and transmitting input data in the web browser to a server;
The program generation method characterized by performing.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2012220511A JP2014074947A (en) | 2012-10-02 | 2012-10-02 | Program generation system and program generation method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2012220511A JP2014074947A (en) | 2012-10-02 | 2012-10-02 | Program generation system and program generation method |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JP2014074947A true JP2014074947A (en) | 2014-04-24 |
Family
ID=50749081
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2012220511A Pending JP2014074947A (en) | 2012-10-02 | 2012-10-02 | Program generation system and program generation method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2014074947A (en) |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2017134800A1 (en) * | 2016-02-04 | 2017-08-10 | 富士通株式会社 | Tabular data analysis method, tabular data analysis program, and information processing device |
| JP2023000795A (en) * | 2021-06-18 | 2023-01-04 | 東京電力ホールディングス株式会社 | Methods, programs and systems for memorizing procedures |
-
2012
- 2012-10-02 JP JP2012220511A patent/JP2014074947A/en active Pending
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2017134800A1 (en) * | 2016-02-04 | 2017-08-10 | 富士通株式会社 | Tabular data analysis method, tabular data analysis program, and information processing device |
| US10970478B2 (en) | 2016-02-04 | 2021-04-06 | Fujitsu Limited | Tabular data analysis method, recording medium storing tabular data analysis program, and information processing apparatus |
| JP2023000795A (en) * | 2021-06-18 | 2023-01-04 | 東京電力ホールディングス株式会社 | Methods, programs and systems for memorizing procedures |
| JP7654192B2 (en) | 2021-06-18 | 2025-04-01 | 東京電力ホールディングス株式会社 | Method, program and system for storing procedures |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN102023989B (en) | Information retrieval method and system thereof | |
| US7840601B2 (en) | Editable table modification | |
| JP6623754B2 (en) | Tabular data processing program, method and apparatus | |
| CN107111639B (en) | Build reports | |
| JP6283190B2 (en) | Tabular data processing program, method, and apparatus | |
| WO2005050447A1 (en) | Batch processing device | |
| JP4846012B2 (en) | Business flow search system, business flow search method, and business flow search program | |
| Cui et al. | A mixed-initiative approach to reusing infographic charts | |
| JP2002063180A (en) | Method for retrieving used car retrieval support system | |
| US20090024667A1 (en) | Information processing device, file data merging method, file naming method, and file data output method | |
| Tateosian | Python For ArcGIS | |
| WO2018005263A1 (en) | Constructing new formulas through auto replacing functions | |
| JP6320901B2 (en) | Data linkage support system and data linkage support method | |
| JP2010015458A (en) | Program correction support system, program correction support method, and program correction support program | |
| JPWO2011148565A1 (en) | Database, management server, and management program | |
| JP2000285128A (en) | Business analysis system | |
| JP2017072957A (en) | File edition method, file edition device and file edition program | |
| JP2014074947A (en) | Program generation system and program generation method | |
| JP2012159952A (en) | Computer program, test support method and test support device | |
| WO2011084374A2 (en) | User interface for building a search query | |
| KR20200119108A (en) | Method for constructing database in WYSIWYG based website builder | |
| Salcedo et al. | SPSS statistics workbook for dummies | |
| JP6339932B2 (en) | Data management apparatus, data management method, and data management program | |
| JP4461111B2 (en) | Batch system design drawing automatic generation method | |
| JP5497948B1 (en) | Tabular data processing program, method and apparatus |