Back

[SOLVED] Unable to create multiple relationship attributes

  • 0
  • Databases
Hemish11
23 Oct, 2023, 16:47

and this command seems to work

TL;DR
Support thread summary: The user was unable to create multiple relationship attributes. The problem was related to the issue of creating a one-way relationship but with the need to create an attribute in another collection. The solution involved using a two-way key as a workaround. Adding the command --twoWayKey solved the issue and allowed the relationship attribute to be created without any additional parameters. The user suggested adding this command as a temporary solution in the GitHub issues.
Hemish11
23 Oct, 2023, 16:48

How about I add this command as a temporary wayaround on making this work in github issues

Drake
23 Oct, 2023, 16:48

this is exactly it? no additional params?

Hemish11
23 Oct, 2023, 16:48

nope

Hemish11
23 Oct, 2023, 16:49

the --twoWayKey seems to do the job done

Hemish11
23 Oct, 2023, 16:49

removing it makes it fail

Hemish11
23 Oct, 2023, 16:49

i tried all the different permutations with it

Hemish11
23 Oct, 2023, 16:49

ideally two way key shouldnt be passed in a one way relationship but its the thing which is alowing to make it work

Drake
23 Oct, 2023, 16:53

interesting ya..

Hemish11
23 Oct, 2023, 16:53

yes

Hemish11
23 Oct, 2023, 16:53

also do note down this observation in github or so, as i just checked both the issues, its not mentioned anywhere

Hemish11
23 Oct, 2023, 16:53

it can be helpful in solving it

Drake
23 Oct, 2023, 16:54

btw, the 1st one is the issue related to your problem. and there was a suggestion for using two way key

Hemish11
23 Oct, 2023, 16:55

But that one also creates a relation attribute in another collection

Hemish11
23 Oct, 2023, 16:55

in this one, there is no attribute what so ever in the other collection

Hemish11
23 Oct, 2023, 16:55

Its like exactly the same way as the normal one way relationship is created

Drake
23 Oct, 2023, 16:56

no it's the same thing. just with different types

Hemish11
23 Oct, 2023, 16:56

Isnt it that if i create doing same in console, i need to force it for two way and that would create attribute in another collection

Hemish11
23 Oct, 2023, 16:57

Doing this doesnt creates any other attribute and is the exact one way relationship

Drake
23 Oct, 2023, 16:57

ya only because the console won't show the key if you don't select two way. this is only for hte workaround

Drake
23 Oct, 2023, 16:57

yes, your workaround is a little different

Drake
23 Oct, 2023, 16:57

im just saying the problem you're having is the same problem as the 1st issue

Hemish11
23 Oct, 2023, 16:57

in my case i didnt wanted it to create attribute in another collection nothing else

Hemish11
23 Oct, 2023, 16:58

totally agreed

Hemish11
23 Oct, 2023, 17:30

[SOLVED] Unable to create multiple relationship attributes

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more