# CSV Import with hurdles (Delimiter?)

**URL:** <https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860>\
**Category:** Ideas & Features\
**Created:** [July 28, 2023, 12:34pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860 "2023-07-28T12:34:49Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 12:34pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/1 "2023-07-28T12:34:49Z")

</div>

Hi,

i finally found a way to export all my Obsidian notes to a csv.

and immediately there are new hurdles:

as there are a lot of “;” in my normal text documents, these are interpreted as delimiter and therefor detroying all the data.  
i now used VS Code to replace all ; with something else and then change the new delimiter i used (~) to “;” but it would be great to have an option to set this in fibery directly… as this is a horrible workflow … especially considering if there is some kind of automation involved in the future getting new files over.

🙂 thanks!

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [July 28, 2023, 1:01pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/2 "2023-07-28T13:01:49Z")

</div>

If you are getting a CSV file, then the contents of the cells should be wrapped in quotes if they contain symbols that could be interpreted as delimiting.

e.g.  
Name, TextField  
Hello, “This is a line, with commas; and it uses other punctuation!”

rather than  
Name, TextField  
Hello, This is a line, with commas; and it uses other punctuation!

Is that not happening when you export from Obsidian?

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 1:16pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/3 "2023-07-28T13:16:24Z")

</div>

Thanks! with your tipp i found an option in the settings of the CSV export plugin

now there is only one more thing: by exporting this as csv the markdown syntax is gone and also new line breaks are broken. the exporter let me put [CR] instead of the new lines. is there any “code” that i can interpret line breaks (i can change the [CR] into anything with VS code of course

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [July 28, 2023, 1:22pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/4 "2023-07-28T13:22:17Z")

</div>

> [@dukevannori](#):
>
> by exporting this as csv the markdown syntax is gone and also new line breaks are broken.

That’s disappointing.  
I believe it should be possible to retain markdown within CSV files, so I don’t know why Obsidian would not do that.

Name, TextField  
Hello, “#Heading# This is an \*important\* piece of info”

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [July 28, 2023, 1:23pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/5 "2023-07-28T13:23:44Z")

</div>

Unfortunately, markdown and CSV are not quite as standardised as people would like, so portability tends to often be less than 100% reliable.

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 1:38pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/6 "2023-07-28T13:38:47Z")

</div>

i don’t care so much about the formatting … but the line breaks are a bit disturbing…

any way of maintaining them (with \n for example it does not work either) or changing them in fibery later on?

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 1:40pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/7 "2023-07-28T13:40:34Z")

</div>

(obsidian in itself does not support export to csv at all… its just a plugin someone programmed, and the whole prozess its definetly not made to export the whole file content as it gets really slow when there are 100s of files in a folder to export)

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 2:04pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/8 "2023-07-28T14:04:19Z")

</div>

WORKAROUND question:

another way of doing this would be to have fibery get the markdown file by filename. so i just import the csv table with the table data and then get the markdown from a markdown file that is on a server to be imported into the rich text field … would that be possible? (in an “semi” automatic way?)

thanks!

(why so complicated: i have extensive use of YAML frontmatter and inline data fields from Obsidian, that i want to translate into cells in fibery. and i dont see a way of having “both” the markdown AND the cells… as either i can import the MD files and have them as files in the space, OR i have the cells without the right markdown … and because i dont have extensive programming knowledge to get this through an API or something i am completely lost… but its more than a thousand files so doing it manually is not an option …)

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [July 28, 2023, 3:48pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/9 "2023-07-28T15:48:38Z")

</div>

> [@dukevannori](#):
>
> another way of doing this would be to have fibery get the markdown file by filename. so i just import the csv table with the table data and then get the markdown from a markdown file that is on a server to be imported into the rich text field … would that be possible? (in an “semi” automatic way?)

We have [markdown import](https://the.fibery.io/@public/User_Guide/Guide/Import-from-Markdown-187) as well as csv import, so it’s beginning to sound like we might be reaching a satisfactory workaround 🤞

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 28, 2023, 4:07pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/10 "2023-07-28T16:07:17Z")

</div>

is there a way to link by name or import by name? curious what you will come up with 🙂

the markdown import is great btw!

but I don’t want to have them files all separate. i want their data in a DB 😉

thanks!

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [July 28, 2023, 6:30pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/11 "2023-07-28T18:30:48Z")

</div>

> [@dukevannori](#):
>
> is there a way to link by name or import by name?

I don’t know what this means, sorry

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [July 29, 2023, 10:09am UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/12 "2023-07-29T10:09:46Z")

</div>

Oh sorry for being unclear.

I mean would it be possible to import the markdown file by the name stored in a database. See, I get the CSV with all relevant data and have the name of the markdown file as name of the database entry. So if there is some kind of automation that could either import the corresponding markdown or take the corresponding markdown file that is already imported from a space and put it as a rich text field, this would be golden.

So, in example “database entry name = file1; look for markdown file1 in space ‘imported markdownfiles’, copy content, put in database entry content field where name is file1”. Run for all entries

Sadly chatgpts programming skills are not good enough 🙂

---

<div class="post-metadata">

**Author:** ![kalman](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/kalman/32/4704_2.png) [@kalman](https://community.fibery.io/u/kalman)\
**Post date:** [August 1, 2023, 3:42am UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/13 "2023-08-01T03:42:30Z")

</div>

> [@dukevannori](#):
>
> I mean would it be possible to import the markdown file by the name stored in a database. See, I get the CSV with all relevant data and have the name of the markdown file as name of the database entry. So if there is some kind of automation that could either import the corresponding markdown or take the corresponding markdown file that is already imported from a space and put it as a rich text field, this would be golden.
> 
> So, in example “database entry name = file1; look for markdown file1 in space ‘imported markdownfiles’, copy content, put in database entry content field where name is file1”. Run for all entries

Unfortunately, this is not possible today. Although this is in our backlog, there is no ETA for release.

---

<div class="post-metadata">

**Author:** ![dukevannori](https://avatars.discourse-cdn.com/v4/letter/d/8c91f0/32.png) [@dukevannori](https://community.fibery.io/u/dukevannori)\
**Post date:** [August 11, 2023, 12:21pm UTC](https://community.fibery.io/t/csv-import-with-hurdles-delimiter/4860/14 "2023-08-11T12:21:51Z")

</div>

i posted it elsewhere, but if you are interested in a workflow to get obsidian files in fibery (without the CSV) you can look at n8n:

> **[Obsidian to Fibery](https://community.n8n.io/t/obsidian-to-fibery/29084/10)**
>
> for those who are interested here is my workflow - i removed all tokens and secrets. it takes new files from a folder in google drive extracts the meta from the YAML Frontmatter, and then from the body of the file Frontmatter= key: value Body=...

the javascript that picks apart the Markdown can be adapted to work on a button inside fibery too i guess? it looks like this

```auto
var mdData = $json.data;

// Split the markdown content into sections
const sections = mdData.split(/(?:\n---\n|> \[!Meta\]\n)/);

// Initialize variables for extracted data
const extractedData = {};

// Check if a frontmatter section exists
if (sections.length > 1) {
    // Extract data from frontmatter section
    const frontmatterLines = sections[0].split('\n');
    frontmatterLines.forEach(line => {
        const match = line.match(/^\s*([^:]+):\s*(.*)$/);
        if (match) {
            const key = match[1].trim();
            const value = match[2].trim();
            extractedData[key] = value;
        }
    });
}

// Extract data from body section
const bodyLines = sections[sections.length > 2 ? 2 : 1].split('\n');
bodyLines.forEach(line => {
    const match = line.match(/^\s*([^:]+)::\s*(.*)$/);
    if (match) {
        const key = match[1].trim();
        const value = match[2].trim();
        extractedData[key] = value;
    }
});

// Extract data from meta section
if (sections.length > 2) {
    const metaLines = sections[sections.length > 2 ? 3 : 2].split('\n');
    metaLines.forEach(line => {
        const match = line.match(/^\s*([^:]+):\s*(.*)$/);
        if (match) {
            const key = match[1].trim();
            const value = match[2].trim();
            extractedData[key] = value;
        }
    });
}

return(extractedData);

```

the file is a bit more complex than it would need if data is kept the same throughout the vault. but mine are a mix of frontmatter YAML and “postmatter” callouts
