Steps:
- Create a folder inside HI Repository. In this case we have created a folder named “CSV Datasource”.
- Inside this folder create another folder and save the CSV file inside it. In our case we have created a folder named “CSV”.
- Place the CSV which you intend to use in this folder. Please make sure that the CSV which you are putting is having datatype defined in the header.
- Meeting_Agenda:string
- Cost:double
- Timeline:date
- boolean
- byte
- char
- short
- int
- long
- float
- double
- string
- date
- After that create a CSV Model JSON file.
- After that create an EFWD (database connection file) file in
C:\Helical Insight\hi-repository\CSV Datasource
Content of EFWD file is present below.<EFWD> <DataSources> <Connection id="1" name="Travel CSV Datasource" type="sql.calcite"> <model>CSV datasource/csv-model.json</model> <driverName>org.apache.calcite.jdbc.Driver</driverName> </Connection> </DataSources> </EFWD>
-
Now go to the “Meta Data” tab of Helical Insight application, select “Create” option to create metadata. Then select “Virtual Datasource” option from the list of available Datasource Type. Then from the list you can select the created CSV Datasource to create metadata and created metadata is then used for report creation in Adhoc.
C:\Helical Insight\hi-repository\CSV Datasource
C:\Helical Insight\hi-repository\CSV Datasoure\CSV
Note: Make sure that there are no special characters in the CSV that you create.
Datatype format to use in a CSV :
Column_Name : Datatype_Name
Example:
List of Datatypes Available :
inline: { version: '1.0', defaultSchema: 'Travel CSV', schemas: [ { name: 'Travel CSV', type: 'custom', factory: 'org.apache.calcite.adapter.csv.CsvSchemaFactory', operand: { directory: 'C:/Helical Insight/hi-repository/CSV Datasource/CSV' } } ] }
For further assistance, kindly contact us on support@helicalinsight.com or post your queries at forum.helicalinsight.com