nopSolutions / nopCommerce

ASP.NET Core eCommerce software. nopCommerce is a free and open-source shopping cart.
https://www.nopcommerce.com
Other
9.3k stars 5.32k forks source link

MySql database support #415

Closed mariannk closed 4 years ago

mariannk commented 8 years ago

We might support MySql to draw some attention from the open source community. Sql server is a bit pricey and in some countries they just don't want to use

turgayozgur commented 5 years ago

@ekuiperemr There is no hard coded db name of nopdata but I don't understand why it use that the name of database.

TopsDesk commented 5 years ago

I am installing visual studio and will try to figure that out.

Is ASP.NET sufficient for nopCommerce? or I need to install additional components?

Thanks, Farooq Khan

On Wed, Jan 30, 2019 at 3:20 PM Turgay notifications@github.com wrote:

@ekuiperemr https://github.com/ekuiperemr There is no hard coded db name of nopdata but I don't understand why it use that the name of database.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/nopSolutions/nopCommerce/issues/415#issuecomment-459113434, or mute the thread https://github.com/notifications/unsubscribe-auth/ADgbafo8RQK7eNQXxZ5IT3cMuIo8C7B3ks5vIgyQgaJpZM4HGx3J .

-- Regards, Farooq Khan

Tel: +1.832.830.6682

TopsDesk commented 5 years ago

I cleaned up everything and tried using other database names besides nopdata. Only database name which works is nopdata.

Again deleted everything and uninstalled dotnet 2.1.503 and then installed dotnet 2.2.1 - Exactly same results, only dbname of nopdata works.

Update: I let it run for a day and kept on doing small things. In the morning today Nop4.10 crashed and would not start at all. Any attempt to restart Nop4,10 returns the following error. Filing a ticket with NopCommerce.

dotnet run --project Presentation/Nop.Web /usr/share/dotnet/sdk/2.2.103/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.DefaultItems.targets(153,5): warning NETSDK1071: A PackageReference to 'Microsoft.AspNetCore.App' specified a Version of 2.1.2. Specifying the version of this package is not recommended. For more information, see https://aka.ms/sdkimplicitrefs [/var/www/fivecent/nopCommerce/src/Libraries/Nop.Core/Nop.Core.csproj] info: Microsoft.EntityFrameworkCore.Infrastructure[10403] Entity Framework Core 2.1.1-rtm-30846 initialized 'NopObjectContext' using provider 'Pomelo.EntityFrameworkCore.MySql' with options: using lazy-loading proxies info: Microsoft.EntityFrameworkCore.Database.Command[20101] Executed DbCommand (59ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT t.Id, t.Enabled, t.LastEndUtc, t.LastStartUtc, t.LastSuccessUtc, t.Name, t.Seconds, t.StopOnError, t.Type FROM ScheduleTask AS t WHERE t.Enabled = TRUE ORDER BY t.Seconds DESC info: Microsoft.EntityFrameworkCore.Database.Command[20101] Executed DbCommand (0ms) [Parameters=[], CommandType='Text', CommandTimeout='30'] SELECT s.Id, s.CompanyAddress, s.CompanyName, s.CompanyPhoneNumber, s.CompanyVat, s.DefaultLanguageId, s.DisplayOrder, s.Hosts, s.Name, s.SslEnabled, s.Url FROM Store AS s ORDER BY s.DisplayOrder, s.Id

Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object. at Nop.Services.Tasks.TaskThread.TimerHandler(Object state) in /var/www/fivecent/nopCommerce/src/Libraries/Nop.Services/Tasks/TaskThread.cs:line 86 at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state) --- End of stack trace from previous location where exception was thrown --- at System.Threading.TimerQueueTimer.CallCallback() at System.Threading.TimerQueueTimer.Fire() at System.Threading.TimerQueue.FireNextTimers()

wingback commented 5 years ago

Why this was changed just to MySql? PostgreSQL will not be supported?

mkrauklis commented 5 years ago

Is there an eta for 4.3 (or a 4.2.x with MySQL support)?

Batnik commented 5 years ago

this is an ultra old issue, can we know when mysql will be definitely supported?

atlv24 commented 5 years ago

Whats the status on this?

DavidMills02 commented 5 years ago

The last release was expected to support MySql - is there any hope that the next release will?

wakelift commented 5 years ago

Hi! Awesome database extension you've made; I'm super grateful for it and very happy it's done. One question - how are stored procedures handled? I'm looking at the MySQL DB instance, and they're not there. I'm also getting an error on the DeleteGuests tasks, it's complaining about the OUT/OUTPUT parameter in the SP, but I'm still not even sure how it's getting run. Have you or anyone else come across this? Thanks a ton :)

bugproof commented 4 years ago

I was taking a look at the code and there is a bunch of stored procedures in .sql files specific to SQL server. Any reason why it's not written in C#?

zandiarash commented 4 years ago

I was taking a look at the code and there is a bunch of stored procedures in .sql files specific to SQL server. Any reason why it's not written in C#?

I think Stored procedures bring an amazing performance out of the box. C# with EF cannot execute as rapid as stored procedures.

yashvit commented 4 years ago

@skoshelev @exileDev Is feature on schedule to complete before the 4.30 release? Thanks.

exileDev commented 4 years ago

@yashvit We just recently merged this feature into the develop branch

AndreiMaz commented 4 years ago

And done. it'll be available in 4.30

JwanKhalaf commented 4 years ago

Does this mean it is now available for Postgres too?

AndreiMaz commented 4 years ago

@JwanKhalaf there's a separate work item for Postgre - https://github.com/nopSolutions/nopCommerce/issues/3794

zandiarash commented 4 years ago

@AndreiMaz It Is amazing... By the way, is It a way to migrate our websites which uses sqlserver to mysql ?

skoshelev commented 4 years ago

Hi @zandiarash. You may use the external tools to migrate your data, MySQL Workbenc for example.

Coco0185 commented 4 years ago

Hi ,

Im trying to instal nopCommerce_4.30_NoSource. I have Mamp launched and i am using my sql which is running on the default port 3306 on localhost.

It doesn't work below the screenshots : image image image

Thank you for your help

Coco0185 commented 4 years ago

Hi Anyone can help me?

Thank you

exileDev commented 4 years ago

@Coco0185 You specify the port in Server name field, but you don’t need to do this. nopCommerce specifies it by default.

huntertran commented 4 years ago

@Coco0185 I got the same error. Have you found a fix?