database – which table to store data like simple product in Magento2?

Stack Exchange Network

Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

What does it mean that a “clustered index does not store pointers to the data”?

I am a beginner in SQL and Database Administration and I am trying to undestand the difference between clustered and non-clustered indexes. More or less I understood what the different tasks are but I have some issues when it comes to the question of “pointers”. I don´t come from CS so I have some issue to imagine what happens at the “leaf level” with the pointers and in which way they connect the index to the data. So, what does it mean that a clustered index does not store pointers to the data, while, the non-clustered one, does it?

Sorry in advance if these questions sound stupid but at this point I am pretty confused!

encryption – Group Instant Messaging: How to securely store messages on the backend while supporting cross-device message history in a group chat?

I want to build a group chat app where messages are transmitted and stored as securely as they can be, but where the message history is still visible after you or others in the group have changed devices. From my understanding, PFS isn’t possible here.

It seems that WhatsApp has implemented PFS, which makes sense because its experience is such that, if you change devices, the previous history is gone/not decryptable. But, after researching Messenger and Discord, seems that they store everything in cleartext? Messenger has a “secret messages” mode, which appears to use PFS, however.

Anyway, my first thought here is to have two public/private key pairs for the user (account, and device), and one symmetric key for the group to decrypt messages. For the sake of simplicity, this example assumes that a user can only be in one group chat. My thought is that it would work this way:

  1. A user has a public/private key pair generated when they sign up (we will refer to this as the account encryption key pair). This will be used for direct user-to-user messaging where history needs to be kept.
  2. When a user logs into a device, they generate a public/private key pair for the device. The public key from this pair is sent to the server. The server then sends the user the account key pair and the group chat’s symmetric key, and both are encrypted with the device’s public key.
  3. If the user changes devices, a new device key pair is generated.

This obviously adds a level of safety, but I’m still uncomfortable with this approach, because nothing prevents someone from getting around the server permissions (though there will be IAM) and grabbing all these keys. I also am not sure the best way to store the group chats’ symmetric keys.

Another constraint is that I may not be able to store duplicate messages that are encrypted with everyone’s public keys because of storage costs. Please also assume that a key management service like Keysafe or KMS is available, though they obviously come with limits.

What do you guys think? Am I being stupid? I looked at some other similar posts, but saw answers that didn’t include tangible solutions.

Store data in Local Storage from JSON file

I am trying to store data in the local Storage from my JSON file. But I am getting an empty array in the local Storage. File name is 'data' in the project.
"friends": (
"id": 0,
"name": "Daugherty Gould"
"id": 1,
"name": "Foley Carpenter"
"id": 2,
"name": "Brewer Vinson"

localStorage.setItem('firstName', );

I am not getting the right output with above code. How can I get all the names in localstorage.

Thank you in advance!

8 – How do I flag the update store automatically?

I created a flag to flag the stores. I want when a user updates a store, the store is automatically flagged. The code below does not work and there is no error message.

I don’t want to use the Rules module.

How do I flag the update store automatically ?


function admin_task_notify_entity_update(DrupalCoreEntityEntityInterface $entity) {

  // Flag store.
  if ($entity->getEntityTypeId() == 'commerce_store') {
    $flag_id = 'report_store';

    $flag_service = Drupal::service('flag');
    $flag = $flag_service->getFlagById($flag_id);

    $flag_service->flag($flag, $entity);


magento2 – Full-page cache breaks store switcher

FPC is activated on the site. When I switch the store view on the Home page the Category page changes the language but the switcher remains unchanged.

The store code is added to the cookie correctly.
If you go to the Login page, the switcher changes its status, but when you go back to the Homepage, the status changes to incorrect

How do I resolve this bug?

8 – Creating a content type/reference entity to store product feature comparison data

I want to be able to manage the data in the table above using Drupal 8 content types/reference entities. I am not sure how to explain this in words. Please have a look at the image attached.

enter image description here

At first I thought I will create a content type called feature with 4 fields groups for each product. But when a product is edited/created, I have to change the content type and edit all the features.

Then I thought of creating the Product a content type and making the feature a field. But that would create the same problem.

As of now, the best way of doing this is creating a taxonomy for features and content type for products. Then I create a custom field consisting of an entity reference (for the feature) a checkbox (for the tick) and a text field (for the optional text).

I then add the custom field to the product content type.

I know, the problem of products/features changing or new ones created is still an issue. But at least I have to change the feature in one place(taxonomy term).

magento2 – Magento 2 product save in store “0” instead of store “1” in single store mode

When I save my product, it saved in store view “0” (admin)

So the modification is not showing in the front-office.

But when I change the price, it directly changed in store view “1”.

How can I save this product in store view “1” without change single store view mode ?

PS : I used for migrate data to 1.9 to 2.3

google play store – My app unavailable for any phone I want to install it on

I’ve built an app a year ago, but it was barely functional. A year later (this week) I had some time to do some fixes here and there, so I did, and rebuilt the app. When uploading it to Google Play, the store told me I need to have my minimal API set to 29. Alright then, upgraded the API, uploaded again.

Aaaand it’s not available for any of the phones I can use (mostly Xiaomi Redmi line, 5 and 6A). Seems like the API update excluded all the phones from instalation viability.

Is there something I’m missing here, or is that really it? I’d really like to be able to install my own app and test it on mobile devices.

App in question:
Link to Google Play Page

Store data in Local Storage from JSON file

I am trying to store data in the local Storage from my JSON file. But I am getting an empty array in the local Storage. File name is ‘data’ in the project.
“friends”: (
“id”: 0,
“name”: “Daugherty Gould”
“id”: 1,
“name”: “Foley Carpenter”
“id”: 2,
“name”: “Brewer Vinson”

localStorage.setItem(‘firstName’, );

I am not getting the right output with above code. How can I get all the names in localstorage.

Thank you in advance!