mothership-ec / mothership

A basic installation of Mothership ready to download
Other
30 stars 6 forks source link

Issues with setting up database in MySQL 5.7 #45

Open thomasjthomasj opened 8 years ago

thomasjthomasj commented 8 years ago
- Ran up cog://@Message:Mothership:Voucher::resources/migrations/_1379342457_SetUp.php
- Ran up cog://@Message:User::resources/migrations/_1379408417_SetUp.php
- Ran up cog://@Message:Mothership:FileManager::resources/migrations/_1379411088_SetUp.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1379411228_SetUpOrders.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1379411978_SetUpProducts.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1379413375_SetUpUsers.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1379413937_SetUp.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1379413937_SetUpBasket.php
- Ran up cog://@Message:Mothership:Discount::resources/migrations/_1379414517_SetUp.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1379498312_SetUpForex.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1379508969_UpdatePageTranslationTable.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1380199741_UpdatePageTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1380277368_UpdateForexTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1380535234_ChangeProductImageIDToHash.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1380638641_UpdateOrderCreate.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1380892582_OrderItemReturnNote.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1382545736_AbstractItemPersonalisationKeys.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1383147378_CreateStockSnapshot.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1383561143_UpdateOrderAddress.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1383562252_UpdateOrderDispatch.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1383850126_UpdateOrderAddress.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1383852384_UpdateOrderAddress.php
- Ran up cog://@Message:Mothership:User::resources/migrations/_1383909255_UpdateEmailSubscription.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1384276019_UpdateOrderDispatch.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1390483991_UpdateForexRate.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1391093236_ProductType.php
- Ran up cog://@Message:Mothership:Voucher::resources/migrations/_1391527092_StartAt.php
- Failed to run up cog://@Message:Mothership:OrderReturn::resources/migrations/_1391686934_CreateReturnAndReturnItemTables.php
    with message: "Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'test.oir.return_id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by"
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1392653226_SetUpTransactions.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1392719777_DatabaseDeletedColumns.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1392896459_AddOrderItemActualPrice.php
- Ran up cog://@Message:Mothership:Discount::resources/migrations/_1394460078_RemoveLocale.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1395164293_AddOrderPaymentChange.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1396365308_UpdateTransactionUpdatedMetadata.php
- Ran up cog://@Message:Mothership:Discount::resources/migrations/_1398866595_DiscountEmail.php
- Ran up cog://@Message:Mothership:ControlPanel::resources/migrations/_1398953239_CreateStatisticTable.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1399565209_RemoveResolutionFromReturnItem.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400061389_AddDeletedColumnsToReturnTable.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400083881_AddRemainingBalanceColumnToReturnTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1400150176_DecoupleRefundsFromOrders.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400151337_CreateReturnRefundTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1400163185_DecouplePaymentsFromOrders.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400165660_ChangeReturnedStockLocationColumn.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400496399_CreateReturnPaymentTable.php
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1400575591_BasketBlobToLongBlob.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400584201_ChangeRemainingBalanceColumn.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1400599470_SortNameField.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400665369_AddActualPriceToReturnItemTable.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400665387_AddCurrencyIDColumToReturnTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1400687900_AddCurrencyIdToBasePaymentsAndRefunds.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1400690356_ChangeReturnedStockLocationColumn.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1401182325_AddTypeColumToReturnTable.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1401184475_UpdateDataToMatchMigrationState.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1401715946_AddOrderItemBasePrice.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1402051241_AddReturnedStockColumn.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1402936340_DefaultBarcodesToUnitId.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1405516571_MakeDispatchesDeletable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1410360627_DefaultSkusToUnitID.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1411476977_AddShippingStatusCode.php
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1411575717_ProductUpload.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1415804834_OrderItemTaxRates.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1416224353_CommentTable.php
- Ran up cog://@Message:Mothership:OrderReturn::resources/migrations/_1417011425_ReturnItemTaxes.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1417615401_OrderShippingTax.php
- Ran up cog://@Message:Mothership:User::resources/migrations/_1421406254_AddUserAddressTableIfNotExists.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1423739640_AddExportCode.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1424772091_ChangeProductDetailValueType.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1424794860_DeleteDeprecatedComments.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1426241749_ProductImageOptionsImageIDFix.php
- Ran up cog://@Message:Mothership:CMS::resources/migrations/_1427287552_MetaImage.php
- Ran up cog://@Message:Mothership:Discount::resources/migrations/_1436880434_CreateBundleTable.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1437641846_DiscountTypeField.php
- Failed to run up cog://@Message:Mothership:User::resources/migrations/_1438004331_UserProfiles.php
    with message: "All parts of a PRIMARY KEY must be NOT NULL; if you need NULL in a key, use UNIQUE instead"
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1440409241_PageUnitRecord.php
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1440409242_PortProductUnits.php
- Ran up cog://@Message:Mothership:Commerce::resources/migrations/_1444911212_AllowNullOnBarcode.php
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1447926198_PaymentGateway.php
- Ran up cog://@Message:Mothership:Ecommerce::resources/migrations/_1447928067_MapManualPayments.php
adamyeats commented 8 years ago
PHP Fatal error:  Uncaught exception 'Whoops\\Exception\\ErrorException' with message 'Uncaught exception 'Message\\Cog\\DB\\Exception' with message 'Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'mothership_base.order_summary.created_at' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by' in /Users/adamyeats/Code/mothership-base/vendor/mothership-ec/cog/src/DB/Query.php:62

We might need to check out whether only_full_group_by is enabled in all new 5.7 installs. If not, then it might be safe just to globally turn this option off in my local database.

Grendel7 commented 8 years ago

I just tried to setup Mothership as well on MySQL version 5.7.13-0ubuntu0.16.04.2 and I got this problem as well.

It looks like only_full_group_by is enabled by default starting with MySQL 5.7.5: http://dev.mysql.com/doc/refman/5.7/en/sql-mode.html#sqlmode_only_full_group_by