phpmyAdmin을 사용하여 XAMP에서 json 데이터베이스를 만들려고하고 있는데 mariaDB를 사용하고있는 것으로 나타 났지만 xamp-control panel v3.2.2
에서는 mySQL on port 3306
이 표시됩니다. 심지어mariaDB Laravel의 JSON 지원
SQLSTATE[42000]: Syntax error or access violation: 1064 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 'json null,
content
json null,scripts
json null,deleted_at
timestamp null' at line 1 (SQL: create tablepages
(id
int unsigned not null auto_increment primary key,title
varchar(191) not null,slug
varchar(191) not null,styles
json null,content
json null,scripts
json null,deleted_at
timestamp null,created_at
timestamp null,updated_at
timestamp null) default character set utf8mb4 collate utf8mb4_unicode_ci)
: 나는 다음과 같은 오류가있어이를 실행하는 동안 이제
Schema::connection('newPortal')->create('pages', function (Blueprint $table){
$table->increments('id');
$table->string('title');
$table->string('slug')->unique()->index();
$table->json('styles')->nullable();
$table->json('content')->nullable();
$table->json('scripts')->nullable();
$table->softDeletes();
$table->timestamps();
});
을 : 나는 다음과 같은 데이터베이스를 만들 Laravel 5.4 프레임 워크를 사용하고있어 내가 실행하기 위해 노력하고있어 내 마이그레이션입니다 null이 아니면 같은 오류가 발생합니다. json 형식의 데이터를 갖고 싶습니다. 지원되는 버전을 확인하고 json 형식 지원을 버전 MariaDB 10.0.16.
에서 시작하여 사용하고 있습니다. 10.1.21-MariaDB
도와주세요.
당신이 데이터베이스 GUI 또는 REPL에서 해당 쿼리를 실행 한 후 밖으로 쿼리의 각 부분을 주석 시도 가지고 JSON 데이터 타입에 대한 별칭이 한 줄씩? 정확한 문제가 무엇인지 밝힐 수 있습니다. – Spholt