Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> [MySQL]Dlaczego zamiast mysql mam MariaDB?
Neutral
post 20.08.2016, 11:04:35
Post #1





Grupa: Zarejestrowani
Postów: 286
Pomógł: 46
Dołączył: 10.01.2016

Ostrzeżenie: (0%)
-----


Jak to naprawić, bo piszę zapytania sql w mariaDB dla mysql!

MariaDB [(none)]>
Go to the top of the page
+Quote Post
viking
post 20.08.2016, 11:07:12
Post #2





Grupa: Zarejestrowani
Postów: 6 378
Pomógł: 1116
Dołączył: 30.08.2006

Ostrzeżenie: (0%)
-----


Masz taki serwer zainstalowany. Jeśli to vps albo domowy komputer zainstaluj mysql community. Jak hosting z dostępem ssh nic nie zrobisz.


--------------------
Go to the top of the page
+Quote Post
Neutral
post 20.08.2016, 11:11:41
Post #3





Grupa: Zarejestrowani
Postów: 286
Pomógł: 46
Dołączył: 10.01.2016

Ostrzeżenie: (0%)
-----


xamppa mam zainstalowanego.

c:\xampp\mysql\bin>mysql -u root
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 34
Server version: 10.1.13-MariaDB mariadb.org binary distribution

Copyright © 2000, 2016, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

Apache/2.4.18 (Win32) OpenSSL/1.0.2e PHP/7.0.8
Wersja klienta bazy danych: libmysql - mysqlnd 5.0.12-dev - 20150407 - $Id: 241ae00989d1995ffcbbf63d579943635faf9972 $
Rozszerzenie PHP: mysqli Dokumentacja
PHP version: 7.0.8



Serwer: 127.0.0.1 via TCP/IP
Typ serwera: MariaDB
Wersja serwera: 10.1.13-MariaDB - mariadb.org binary distribution
Wersja protokołu: 10
Użytkownik: root@localhost
Kodowanie znaków serwera: UTF-8 Unicode (utf8)
Go to the top of the page
+Quote Post
viking
post 20.08.2016, 11:16:09
Post #4





Grupa: Zarejestrowani
Postów: 6 378
Pomógł: 1116
Dołączył: 30.08.2006

Ostrzeżenie: (0%)
-----


Maria db to fork mysql który ma ten plus ze szybko na bugi reagują. Jeśli chcesz inaczej to zainstaluj wszystko ręcznie. W stopce mam linki do pełnej instalacji serwerów.


--------------------
Go to the top of the page
+Quote Post
Neutral
post 20.08.2016, 11:29:19
Post #5





Grupa: Zarejestrowani
Postów: 286
Pomógł: 46
Dołączył: 10.01.2016

Ostrzeżenie: (0%)
-----


create table mojatabela(
-> int id auto_increment,
-> name varchar(40),
-> countrycode varchar(35));
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'int id auto_increment,
name varchar(40),
countrycode varchar(35))' at line 2

To czemu to nie działa?

Jak to zmienić w xamppie? Da się w ogóle?
Go to the top of the page
+Quote Post
viking
post 20.08.2016, 11:45:00
Post #6





Grupa: Zarejestrowani
Postów: 6 378
Pomógł: 1116
Dołączył: 30.08.2006

Ostrzeżenie: (0%)
-----


Ja ci podalem rozwiązanie instalacji od nowa bez xampp.
Tu masz dokładnie to co w komunikacie. Najpierw podajesz nazwę kolumny, potem typ danych.


--------------------
Go to the top of the page
+Quote Post
Neutral
post 20.08.2016, 14:24:26
Post #7





Grupa: Zarejestrowani
Postów: 286
Pomógł: 46
Dołączył: 10.01.2016

Ostrzeżenie: (0%)
-----


Co jest lepsze MariaDB, czy mysql?
Go to the top of the page
+Quote Post
viking
post 20.08.2016, 14:33:53
Post #8





Grupa: Zarejestrowani
Postów: 6 378
Pomógł: 1116
Dołączył: 30.08.2006

Ostrzeżenie: (0%)
-----


Na większości dystrybucji linuksowych jest mariadb co za tym idzie, na hostingach również. Poczytaj o różnicach i wybierz. Jeśli nie robisz nic skomplikowanego typu wyzwalacze, funkcje nie ma znaczenia. Przy skomplikowanych rzeczach już mi się zdarzało ze wystepowaly niepoprawione bugi w jednym a poprawione były w drugim i vice versa. A lepszy jest postgres ☺


--------------------
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 24.07.2025 - 17:47