cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Databricks Free Edition Help
Engage in discussions about the Databricks Free Edition within the Databricks Community. Share insights, tips, and best practices for getting started, troubleshooting issues, and maximizing the value of your trial experience to explore Databricks' capabilities effectively.
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

creating tables

Thomas_Aimiuwu
New Contributor III
%sql
This in pay-as-you-go
create table if not exists demo.test
(country string,
indicator string,
date string,
year_week string,
value string,
source string,
url string)
using csv
options(path "/mnt/formal1/hospital_admissions.csv")
the above worked in a pay-as-you-go workspace with storage already mounted.
 
Below is Databricks free edition which does work but came back with an error, please is there a workaroud?
%sql
create table if not exists demo.test
(country string,
indicator string,
date string,
year_week string,
value string,
source string,
url string)
using csv
options(path "/Volumes/workspace/demo/raw/hospital_admissions.csv")
AT
1 ACCEPTED SOLUTION

Accepted Solutions

szymon_dybczak
Esteemed Contributor III

Hi @Thomas_Aimiuwu ,

Here's a workaround. Of course adjust following piece of code to your needs.

%sql
SELECT *
FROM read_files(
  '/Volumes/workspace/demo/raw/hospital_admissions.csv',
  format => 'csv',
  sep => ',',
  header => true
);

 The reason why it doesn't work you can find at below thread:

Solved: can I use volume for external table location? - Databricks Community - 61295

View solution in original post

1 REPLY 1

szymon_dybczak
Esteemed Contributor III

Hi @Thomas_Aimiuwu ,

Here's a workaround. Of course adjust following piece of code to your needs.

%sql
SELECT *
FROM read_files(
  '/Volumes/workspace/demo/raw/hospital_admissions.csv',
  format => 'csv',
  sep => ',',
  header => true
);

 The reason why it doesn't work you can find at below thread:

Solved: can I use volume for external table location? - Databricks Community - 61295