Skip to content
This repository has been archived by the owner on Apr 17, 2023. It is now read-only.

SQLite does not support array types #712

Open
Eunovo opened this issue Aug 11, 2020 · 1 comment
Open

SQLite does not support array types #712

Eunovo opened this issue Aug 11, 2020 · 1 comment

Comments

@Eunovo
Copy link
Collaborator

Eunovo commented Aug 11, 2020

While testing filtering with contains operation, I discovered that array types are not saved to the db when using the websql adapter. After some digging, I realised that there is no support for an "Array" type so we can't save arrays naturally.

I think we have two options here,

  • Don't allow array types when using websql
  • Use some alternate method to save arrays, there are a couple of ways to this, see this

@wtrocki @kingsleyzissou

@wtrocki
Copy link
Contributor

wtrocki commented Sep 4, 2020

Split will work only for single dimensional arrays.
I have been playing with SQL lite and I think that we do not need to create proper tables.
Our data can be saved as one column

So our API can be:

await AsyncStorage.setItem( "mykey", "myValue")

However indexed fields will still need to be brought into columns for searchability.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants