Actions

回答のインポート

From LimeSurvey Manual

Revision as of 01:49, 21 February 2019 by Bravehorse (talk | contribs) (Created page with "* 質問が対象から外されました。(無視されます)")


はじめに

回答のインポート機能は、過去の回答をLimeSurveyの回答テーブルにインポートして表示する機能です。この機能は以下の場面で使用します。

  • 2つ以上のLimeSurveyで収集されたすべてのデータを1つのLimeSurveyに結合する場合。さらなる分析のため、すべての回答を把握する目的で行います。
  • ある質問の質問タイプが誤って設定されている場合。LimeSurveyではアンケート実行中は質問タイプを変更することができないので、一旦アンケートを無効にする必要があります。無効にすると、回答テーブルが作成され、LimeSurveyのデータベースに保存されます。必要な変更が完了したら、アンケートを再度アクティブにし、古い回答データベースから回答の再インポートを選択します。
  • 表計算ソフトウェアを使用して複数の行をバッチ編集し、後から再度インポートする場合。例えば、質問タイプを変更し、保存済の回答を新しいフォーマットに"調整する"場合です。


インポート機能にアクセスするには、(アンケート関連のパネルに表示される)メインツールバーから回答と統計を選択し、回答をクリックします。



回答概要ページが読み込まれます。ここで、上部のツールバーにあるインポートオプションを選択します。



Two import options are available:


インポート

停止したアンケートテーブルから回答をインポートする

停止したアンケートテーブルから回答をインポートするをクリックすると、次のページが読み込まれます。



このページでは2つのオプションを選択できます。

  • インポート元のテーブル: インポートしたいテーブルを選択してください。テーブルは互換タブと 質問タイプを強制変更すれば、互換タブの両方に表示されます。後者が何であるか、また回答テーブルのタイプの強制変更に伴うリスクについては、続けて以下を参照ください。
  • 回答タイミングを(もしあれば)インポートする: タイミングは回答テーブルではなくタイミングテーブルに表示されます。有効にすると、タイミングもインポートされます。


To use timings, please enable this feature from here.


ページ上の次のセクションには、2つの回答テーブル間(現在のものと古い/ 2番目のものの間)の互換性がどのように決定されるかを説明する注意メッセージが表示されます。


  注意 :

現在のアンケートと互換性のある古い回答をすべてインポートできます。互換性は、列タイプと名前を比較することによって判断されます。IDフィールドは常に無視されます。

タイプの強制によって、データがこわれるかもしれません。注意して行うか、しなくてすむならしないほうがよいでしょう。

LimeSurveyは以下の変更を検出して処理します。

  • 質問が別の質問グループに移動しました。(正常にインポートされました)
  • 質問が対象から外されました。(無視されます)
  • Question is added to target (result is set to database default value).


VVアンケートファイルをインポートする

If you click the Import a VV survey file button, the following page will be loaded:



  • Response data file: select the file to be uploaded from your machine. The accepted file formats are : *.csv, *.vv, *.txt.


As long as the first two lines are intact, you can import your vv survey file back into an active LimeSurvey survey.


  • Exclude record IDs?: if 'id' column exist in the file you can exclude this line or not. If this setting is checked then a new record is added for each line of the .vv file. If unchecked you can choose:



  • When an imported record matches an existing record ID (displayed if exclude record IDs is disabled, see the above screenshot):
    • skip: report and skip the new record. After upload you will see if the record already existed - if it did it's not imported.
    • renumber: renumber the new record. A new record is added to the response table with answer of the VV file.
    • replace: replace the existing record. The old record is deleted and completely replaced by the record from the VV file.
    • replace answer: replace response details from the vv file into the existing record. The old record is updated with the new response from the VV file.
  • Import as not finalized response?: if checked, the submitdate is set to NULL - the response is set to not completed.
  • Character set of the file: you can choose the character set of the file - the default and recommended value is UTF-8 but some spreadsheet program don't allow to choose a character set.
  • First line contains question codes: iy default, VV file's first line contains the human readable question, the real column names being located on the second line. Basically, the first line contains the real column names.
  • Force import: if the question codes are not found in the database name or in Qcode Variable Naming, then columns are assigned depending of order. This can be used to import the VV file from different LimeSurvey instance. Regardless of this, each survey must be exactly the same. We strongly recommend to use this option only if you know what you are doing. It can be very dangerous - the results can end up in the wrong column.


VVファイルに関する潜在的な問題と解決策

If you used Microsoft Excel to edit the exported vv file, the data structure of this file may be corrupted, so LimeSurvey is not able to import the edited file. You can try the following workaround to get the import working without an error:

  1. Open your exported vv file in Excel and do your edits.
  2. Save it as tab-separated text file (it creates a new file with the extension .txt).
  3. Do another "clean" vv export from LimeSurvey.
  4. Open this new exported vv file with a text editor like notepad (or anything similar).
  5. Press CTRL + A to mark all of the content and delete it.
  6. Open the Excel edited vv file (the tab separated .txt file) with a text editor and press CTRL + A to mark all the content.
  7. Press CTRL + C to copy the content and paste it into the new (now empty) vv file.
  8. Press CTRL + S to save the file as it is (in .csv format).
  9. Try now to import this file.


  Attention : Possible import errors include date format - some system date fields do not allow a NULL value, some do. If the date looks okay but gives an error, use the Excel cell format "2009-12-01".



For other problems & solutions related to the export and import functionalities provided by LimeSurvey, please check the following wiki section. In the case in which you found a bug or something is not working properly/as described in the manual, please open a ticket (via your limesurvey.org administration panel), create a forum post, or submit directly a bug report on our bugs tracker.