Forum Academy Marketplace Showcase Pricing Features

What is the easiest way to store analytics?

I have a datatype called UStats attached to each user. It contains things such as login date, total logins, total deposits/withdrawals etc I’m trying to capture everything about the user, but i’m not sure how to store it. Eg, I want to record the date and time of every login made by the user… is that meant to be a list field on my datatype to capture it or something else?

I’m not intending to compare much on bubble itself but i’m looking to capture a lot of data on how each user uses my app.

Thank you

No, Bubble has a maximum of 10,000 items on a list - what this means is a data type that has a field that is related to another datatype in a list format will max at 10K…however, any data type you create can have an unlimited number of records.

So, when creating a data structure to relate data types in a list you have to consider two aspects of the related field as a list, the first being 10K max records, the other being performance, which seems to be poorer when the list is over 50-100 items if compared to just doing a simple search of a datatype and constraining by a single related field.

An example is a restaurant data type and a Order data type. A restaurant may have more than 10K orders in a year, so a related field as list of Orders is not appropriate and instead should make it so that on the Order data type there is a related field for restaurant. Then do a search for orders and constrain by restaurant to get the total list of orders for that particular restaurant.

In your situation your User is the Restaurant and your Statistics are your Orders.

Create the data type for Statistics and on it have a related field to User.

I also create an option set that would be statistic type to differentiate between the types of stats you want to store.

I have something like this in an app of mine

The use of Hour and Total Minutes make it easier for me to create charts and data visualizations to give a by the hour or a time range comparison of things, such as how many users visited the page using a mobile device vs a desktop between the hours of 12AM and 4AM vs 12PM and 4PM.

You can capture a lot of information and it won’t be a drag on your data storage as there won’t be any files so all the entries are very small in terms of data size.

Learn More

Boston85719 is an expert Bubbler with a decade experience as an educator. Real name Matthew, he has been actively building SaaS apps, marketplace apps, scheduling apps and more for clients, himself and for sale as templates.

As an official Bubble Bootcamp Instructor, he leads Bubble Bootcamps on a regular basis.

Always willing to offer advice via the Bubble Forum, Matthew also offers Private Personal and Group Training Sessions.

Through his site, NoCodeTrainer, Matthew provides a range of tutorials with editor access to help you jumpstart your Bubble development.

Always accessible you can send Matthew a private message via the forum or send an email directly with your requests.

Be sure to checkout the Stripe Integration Course when you are ready to integrate Stripe payments to start monetizing your application via product sales or subscriptions.

Stripe Integration Course

Legend, thank you so much for clarifying this.
Just found this quick video on it too. Combined with your recommendations and it should be good to go :slight_smile:

Btw, how do you differentiate between mobile/desktop views, clicks and impressions?

Mobile vs desktop is simplistic based on the page width…you could take that further and use some plugins to get details of the users device if wanted.

Click is just based on a user clicking a listing card from a search result.

Impressions is complicated and uses the List Shifter Plugin to track the data entries displayed in a repeating group.