This is Russell with Adobe Commerce. In this session, we’re going to cover using the commerce CLI to show configuration values and update them too. We’re going to get a little bit deeper onto where these values are stored and where some of those default values come from. So in this particular use case, what happened was I was logging into one of my local instances of Adobe Commerce and it was requiring me to change my password. And this is because it’s a local environment. I felt it didn’t need to be a forced event. It should actually just be recommended. We’re going to start by connecting to this Adobe Commerce instance using SSH. And then we’re going to search for the current value that controls this password reset. In this case, it should be a Boolean value. So we’re going to head over to our terminal window and we’ll start with the command to see what is the current value for this password configuration. And the command line for this is php space and then bin slash magento. And then it’s config colon show. And then we need to know the path that we’re looking for. So here it’s admin slash security slash password underscore is underscore forced. And if you hit enter, it will return a value. In this case, it’s a one. We knew it was a Boolean value, so it’s going to be a one or a zero. And obviously one means that this is a forced password change. So because this is the admin, I can just prove that this is happening. So now in order to change it, we know that the value that we need to change it to is a zero. So we’re going to go ahead and go back to our terminal and we’re going to type in php space bin slash magento. And then it’s the same config, but here it’s config colon set. And then we’re just going to copy the old path that we used. So admin slash security slash password is forced. And then the only thing we need to do now is we need to do a space and then our new value. So because the old one was one, we want to change it to a zero. We’ll hit zero and hit enter. And as long as we get the message that says the value was saved, we know that we’re good. So we can prove that this worked by heading back to the admin and reloading the page or going to a different page. And it should no longer require us to change our password. It should just not be recommended. And great, it is. And you’ll notice now that there’s a banner that says you should change your password once again, rather than being forced to do so. Now it’s time to discover where some of these values come from and where they’re saved. Anything that is updated through the CLI or the commerce admin, it’s saved as a row in the core underscore config underscore data table. To elaborate on this, it’s probably best to see the data in that table. I’m going to open up another terminal window and it’s already connected to the database. And we’re going to look at the table called core underscore config underscore data. And let’s just see what values have been saved. So the SQL for this is select star from core underscore config underscore data. And then we’re going to do a space and then a backslash capital G. And the reason for that is we just want it to be formatted in a more readable way. And looking here, it looks like there’s about a hundred config values that have been saved at one time or another for this application. Now let’s find just that one that we saved. So we’re going to go to our SQL and we’re going to add something to the end where path equals, and then that same path. So that admin security password is forced. And once again, now we just have our one row. And if you look at the value set for this, it’s zero, which is great because that’s exactly what we just changed it to. This method’s the same for any config values that are saved in the CLI or in the admin. They all end up in this table. Something interesting happens that every once in a while, you’ll look at that database table or you’ll run the CLI and you won’t get anything to respond. And the reason for this is that the values are there, but they have never been saved. So they’re a default value. And so default values, they don’t start off as an entry in core config data. So let’s show you an example for where one of these values are. So in the commerce admin out of the box, it does come with some default email addresses and there’s one for transactional emails. So using the CLI, if you do PHP bin magento and then config show, and then this, this t-r-a-n-s underscore email ident underscore sales and then slash email, nothing’s there. But when you go to the admin and you go to stores, configurations, and then email addresses, and then under the sales representatives, you’ll see that there is a value there. So it’s kind of misleading that the database table, core config data and the CLI return nothing. Once again, this is because it’s a default value. So it is located somewhere. So it is nice sometimes to know where that’s happening at. So there is a place in the code called, and most modules have these, is a config.xml. So you can use grep to find these values. So in this case, we know that the string is sales at example.com. We can use grep to find that in our code. So here’s our command. It’s going to be grep and then dash, you know, r-n-w, and then I’m going to tell it to start in the vendor slash magento folder. And we’re going to look for that string sales at example.com. And there’s two results, more than likely it’s that bottom one. And so, yeah, it says that on line 50, there’s a node for sales at example.com. And this is just one example of those values that are found in the admin or used, but they’re not in the core config data table. And it is very important that you should know that when you save or update these values in the admin or the CLI, once they’re in that core config data, they take priority. So anything that’s set there will take a precedence over the fallback mechanism, which is the XML. So while we’re here looking at the XML, let’s show you how to view the entire XML, including the line numbers. It’s very helpful if you’re new to Adobe commerce and you just want to see what it looks like. If you add the dash n, it adds all of the line numbers. And so here you can find our three nodes that we’re looking for. And there it is right there, the online 50. So now you know where these default configuration values reside. You know where they’re saved when you make a change using the CLI or the admin. And that’s it for the session. We’re all done. I hope you do continue to learn more about Adobe commerce here on experience league, as well as all of the other Adobe products. Thank you.