studio icon indicating copy to clipboard operation
studio copied to clipboard

Export/Copy as JSON feature

Open outerlook opened this issue 6 years ago • 14 comments

Hi! Should there be an issue to track "copy as json" implementation?

I miss this, but I know there are bunch of things coming first. Thanks!

outerlook avatar Nov 29 '19 20:11 outerlook

Isn't this already doing what you were looking for?

image

schickling avatar Nov 29 '19 21:11 schickling

Yes it is here, but I receive this on browser console: image

My prisma2 version is [email protected]... sorry if I'm missing something

outerlook avatar Nov 29 '19 22:11 outerlook

Ouh. I see.

schickling avatar Nov 30 '19 02:11 schickling

Hello! I was looking into this right now. Implementing is trivial, but there's one question that needs answering: How much do we want to copy? For a small dataset with a bunch of relations (I had 5 records with ~15K relations in total), the payload ended up being 11Mb in size. While theoretically there isn't a limit, Firefox & Chrome wouldn't let me copy something that huge to the clipboard. Obviously, even if you have 5000 records with a couple of relations each, this quickly gets out of control.

Maybe we want a strategy to strip parts of records that are less useful. @outerlook What parts do you generally see yourself using?

sdnts avatar Dec 02 '19 10:12 sdnts

I don't know if it is a good workflow, but I'm thinking of using for this:

In my schema there is a "Place", that can have many "Amenity"`s, that are divided in "CategoryOfAmenity". So, place is a thing that will be truly dynamic, I definitely won't need to store this amount of data in JSON. But amenities will be kind of static, as the costumer will just pick from this list what amenities his place may have.

But since I'm in phase of developing this new application, there are many times I need to start a fresh database, and then I need to seed my data. So, the easiest way is store a JSON of the last data (as it really won't change often), I may tweak things directly in studio if needed, then I can easily update my seed files with "Copy as Json".

I would need at least one depth more in a relation, so I can get which category each amenity belongs to. There isn't much data

There are other things I will be seeding like my country's cities and states. Which is Brazil, with around 5500 cities. So, could there be a "Download as Json" for this bigger results, if results pass a size, for example?

Does this clarify already?

outerlook avatar Dec 02 '19 12:12 outerlook

@madebysid I'd suggest showing some kind of confirmation modal in case you're copying more than x amount of data.

schickling avatar Dec 02 '19 12:12 schickling

Moving this to Post-Beta. Absolutely great to have, but not essential for MVP.

matthewmueller avatar Mar 02 '20 10:03 matthewmueller

Hi, any progress on this issue?

Mozartted avatar Jun 19 '22 23:06 Mozartted

An export feature is on the roadmap. It's one of the next bigger features to come, but we don't have a timeline currently for when it'll be available.

petradonka avatar Jun 20 '22 08:06 petradonka

Bumping this as well. Really need an export view to CSV function like we've seen in other tooling like Hasura.

samobletz-claim avatar Mar 08 '23 19:03 samobletz-claim

Bump @samobletz-claim!

lamerson28 avatar Mar 14 '23 18:03 lamerson28

Bump :D

eliasdefaria avatar May 22 '23 18:05 eliasdefaria

Bump

jacobcwright avatar Aug 18 '23 21:08 jacobcwright

Would love to be able to at least select multiple cells and copy and paste!

flawnson avatar Nov 21 '23 19:11 flawnson

We need this !

zdaar avatar May 23 '24 13:05 zdaar

Look forward to having this!!!

TanLoc-CS avatar Jun 04 '24 02:06 TanLoc-CS

Bumping, we need this, look forward to having this

adlonymous avatar Jun 04 '24 21:06 adlonymous