Answers.Body: <p>Craft 4 works fine in MAMP Pro (I'm using v6.6). Bear in mind that 5.7.34 is actually higher than 5.7.8 - these are not decimals, they're semver numbering.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-22T15:14:51.443Z
Answers.Text: Thank you. I was about to try this out, but I'm stucked with this error after the composer create-project: `Your Composer dependencies require a PHP version ">= 8.0.2". You are running 7.4.21`. Any idea why? There's no export PATH in my .bash_profile. I'm not using yet MAMP at this step.
Answers.UserDisplayName: Romain P.
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-22T16:51:48.973Z
Answers.Text: yeh, this is a bit fiddly when you have multiple projects that need php 8 vs 7. There are probably a few different ways of solving this. If you go to MAMP's PHP settings and set your default as 8.1.0, then tick the box that says "Activate command line shortcut..." then MAMP will create a `.profile` file in your home directory which exports the 8.1.0 binary into your $PATH and aliases "php" to point to the 8.1.0 binary. For older projects that still need PHP 7, I duplicated that alias to "php7" and pointed to the MAMP 7.4.21 binary.
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-22T16:55:34.003Z
Answers.Text: To pinpoint which binary you're using, type `which php`. If your $PATH variable is getting set in other places, like .bash_profile, or .zshrc or .bashrc etc, then it might also be a source of confusion. Type `echo $PATH` to see where your shell will look for binaries.
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-22T16:57:57.120Z
Answers.Text: Finally, don't forget to `source` your changes after making any manual updates to your .profile / .bash_profile / .zshrc / .bashrc. Type `source [filename]`. Or restart your terminal session.
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T09:32:37.623Z
Answers.Text: Thank you! I'm still not able to use Craft 4 (because of In `CreateProjectCommand.php line 323:  chdir(): No such file or directory (errno 2)` on install), but the problem should be somewhere else, so I'm already validating your answer. Btw, for the command line use with MAMP: how can you switch efficiently between multiple versions of PHP? And did you get like me warning in the MAMP phpMyAdmin since the move to PHP 8.1?
Answers.UserDisplayName: Romain P.
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T10:35:05.413Z
Answers.Text: Sorry I don't use phpMyAdmin - I'd recommend switching to Sequel Ace as it's much better. Works ok for me. For multiple versions of PHP on the CLI, I edited my ~/.profile file (which was created by MAMP) to include an alias for php7 like this: `alias php7='/Applications/MAMP/bin/php/php7.4.21/bin/php -c "/Library/Application Support/appsolute/MAMP PRO/conf/php7.4.21.ini"'`
  `alias php='/Applications/MAMP/bin/php/php8.1.0/bin/php -c "/Library/Application Support/appsolute/MAMP PRO/conf/php8.1.0.ini"`
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T11:27:25.113Z
Answers.Text: I'm still using phpMyAdmin to still get used to it because some of my hosting still rely on it (and don't enable remote connection). Thank you for the `~/.profile` file info. Does it matter how the alias is named? Here php7, then php. How MAMP does recognize which one to use depending of the context?
Answers.UserDisplayName: Romain P.
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T14:37:02.490Z
Answers.Text: You can call the aliases whatever you like. From this point it's nothing to do with MAMP (other than the fact that we're using MAMP's php binaries), it's simply a bash alias that allows you to have a shortcut to those binaries without typing out the whole thing. So if you're working on a PHP7 project, you might type `php7 ./craft project-config/apply` instead of just `./craft project-config/apply`. Sequel Ace doesn't require you to connect remotely, it does local connections too - you should definitely try it, it's way easier to use than phpMyAdmin, and much faster.
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T15:16:01.023Z
Answers.Text: Thank you! Ok it make senses for the alias prefix, if I add a custom one. Maybe would be a bit painful in use and to remind with a lot of websites / configs. Yes I'm already using Sequel Pro in dev, but some of my hosting provider don't allow remote DB connection. Do you have any reason still using MAMP instead of Nitro?
Answers.UserDisplayName: Romain P.
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-23T15:53:25.463Z
Answers.Text: I tried Nitro a few times, but still feel it gives me no tangible benefits vs the overhead. Virtual machines are also pretty taxing on your local machine's performance. MAMP Pro has worked well for me for many many years, and I'd much rather spend time working on designs and front end code than endless days messing about with VMs. Maybe I'll give it another chance now that I'm running an M1 Mac...
Answers.UserDisplayName: James Smith
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-06-22T13:23:50.370Z
Answers.LastActivityDate: 2022-06-22T13:23:50.370Z
Answers.UserDisplayName: James Smith
Body: <p>I'm used to working with MAMP instead of Nitro and would like to keep this setup as I find it easy to manage my other older setups.</p>
  <p>As MAMP (Pro) support is until MySQL 5.7.34 and as Craft CMS 4 required MySQL 5.7.8+, how can I make it works with this current setup?</p>
  
Tags: <mysql><mamp><craft4>
Title: How to make Craft CMS 4 works with the older version of MySQL of MAMP Pro?
ThreadText: # How to make Craft CMS 4 works with the older version of MySQL of MAMP Pro?
  
  (Asked by: username_0 on 2022-06-22)
  
  I'm used to working with MAMP instead of Nitro and would like to keep this setup as I find it easy to manage my other older setups.
  
  As MAMP (Pro) support is until MySQL 5.7.34 and as Craft CMS 4 required MySQL 5.7.8+, how can I make it works with this current setup?
  
  **Tags:** mysql, mamp, craft4
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2022-06-22. Score: 1 | Accepted answer
  
  Craft 4 works fine in MAMP Pro (I'm using v6.6). Bear in mind that 5.7.34 is actually higher than 5.7.8 - these are not decimals, they're semver numbering.
  
  > **Comments:**
  > **username_0**: Thank you. I was about to try this out, but I'm stucked with this error after the composer create-project: `Your Composer dependencies require a PHP version ">= 8.0.2". You are running 7.4.21`. Any idea why? There's no export PATH in my .bash_profile. I'm not using yet MAMP at this step.  
  > **username_1**: yeh, this is a bit fiddly when you have multiple projects that need php 8 vs 7. There are probably a few different ways of solving this. If you go to MAMP's PHP settings and set your default as 8.1.0, then tick the box that says "Activate command line shortcut..." then MAMP will create a `.profile` file in your home directory which exports the 8.1.0 binary into your $PATH and aliases "php" to point to the 8.1.0 binary. For older projects that still need PHP 7, I duplicated that alias to "php7" and pointed to the MAMP 7.4.21 binary.  
  > **username_1**: To pinpoint which binary you're using, type `which php`. If your $PATH variable is getting set in other places, like .bash_profile, or .zshrc or .bashrc etc, then it might also be a source of confusion. Type `echo $PATH` to see where your shell will look for binaries.  
  > **username_1**: Finally, don't forget to `source` your changes after making any manual updates to your .profile / .bash_profile / .zshrc / .bashrc. Type `source [filename]`. Or restart your terminal session.  
  > **username_0**: Thank you! I'm still not able to use Craft 4 (because of In `CreateProjectCommand.php line 323:  chdir(): No such file or directory (errno 2)` on install), but the problem should be somewhere else, so I'm already validating your answer. Btw, for the command line use with MAMP: how can you switch efficiently between multiple versions of PHP? And did you get like me warning in the MAMP phpMyAdmin since the move to PHP 8.1?  
  > **username_1**: Sorry I don't use phpMyAdmin - I'd recommend switching to Sequel Ace as it's much better. Works ok for me. For multiple versions of PHP on the CLI, I edited my ~/.profile file (which was created by MAMP) to include an alias for php7 like this: `alias php7='/Applications/MAMP/bin/php/php7.4.21/bin/php -c "/Library/Application Support/appsolute/MAMP PRO/conf/php7.4.21.ini"'` `alias php='/Applications/MAMP/bin/php/php8.1.0/bin/php -c "/Library/Application Support/appsolute/MAMP PRO/conf/php8.1.0.ini"`  
  > **username_0**: I'm still using phpMyAdmin to still get used to it because some of my hosting still rely on it (and don't enable remote connection). Thank you for the `~/.profile` file info. Does it matter how the alias is named? Here php7, then php. How MAMP does recognize which one to use depending of the context?  
  > **username_1**: You can call the aliases whatever you like. From this point it's nothing to do with MAMP (other than the fact that we're using MAMP's php binaries), it's simply a bash alias that allows you to have a shortcut to those binaries without typing out the whole thing. So if you're working on a PHP7 project, you might type `php7 ./craft project-config/apply` instead of just `./craft project-config/apply`. Sequel Ace doesn't require you to connect remotely, it does local connections too - you should definitely try it, it's way easier to use than phpMyAdmin, and much faster.  
  > **username_0**: Thank you! Ok it make senses for the alias prefix, if I add a custom one. Maybe would be a bit painful in use and to remind with a lot of websites / configs. Yes I'm already using Sequel Pro in dev, but some of my hosting provider don't allow remote DB connection. Do you have any reason still using MAMP instead of Nitro?  
  > **username_1**: I tried Nitro a few times, but still feel it gives me no tangible benefits vs the overhead. Virtual machines are also pretty taxing on your local machine's performance. MAMP Pro has worked well for me for many many years, and I'd much rather spend time working on designs and front end code than endless days messing about with VMs. Maybe I'll give it another chance now that I'm running an M1 Mac...  
  
  ---
  
  