php 未配置 SQL 方言 (Phpstorm)

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/30411778/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-25 21:46:16  来源:igfitidea点击:

SQL Dialect is Not Configured (Phpstorm)

phpmysqlphpstorm

提问by RAZA MUSTAFA

I am working on Google oauthorization2 and I encounter problem that

我正在使用 Google oauthorization2 并且遇到问题

SQL dialect is not configured

未配置 SQL 方言

That's why my query is not executing and data is going to table.

这就是为什么我的查询没有执行并且数据将被写入表格的原因。

I have listed below both of queries where I encounter problem.

我在下面列出了遇到问题的两个查询。

Tools: PhpStorm 8+ MySQL Localhost

工具:PhpStorm 8+ MySQL 本地主机

$user_exist = $mysqli->query("SELECT COUNT(google_id) as usercount FROM google_users WHERE google_id=$user_id")->fetch_object()->usercount;

$mysqli->query("INSERT INTO google_users (google_id, google_name, google_email, google_link, google_picture_link)
        VALUES ($user_id, '$user_name','$email','$profile_url','$profile_image_url')");

回答by Michael Bolli

Head to File > Settings > Languages & Frameworks > SQL Dialectsand set it for the whole project.

前往File > Settings > Languages & Frameworks > SQL Dialects并为整个项目设置它。

回答by S.Mason

This is a screenshot of how to do that inside the settings: enter image description here

这是如何在设置中执行此操作的屏幕截图: 在此处输入图片说明

This is on version 2016.3

这是 2016.3 版本