关于SQL语句中缺少左括号的令人困惑的错误 [英] Confusing error about missing left parenthesis in SQL statement

查看:497
本文介绍了关于SQL语句中缺少左括号的令人困惑的错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

SQLPLUS说我的sql脚本中的该语句缺少左括号.

SQLPLUS says I have missing left parenthesis with this statement in my sql script..

CREATE TABLE people(
    id INT NOT NULL PRIMARY KEY,
    name VARCHAR2
);

我已经用sftp上传了脚本,那可以和脚本一起玩吗?

I had uploaded my script with sftp, could that have played around with the script?

推荐答案

VARCHAR2是需要最大大小/长度的类型.尝试类似...

VARCHAR2 is a type that needs a maximum size/length. Try something like...

varchar2(50)

您缺少的左括号是围绕大小的括号.

Your missing left parenthesis is the parenthesis that surrounds the size.

CREATE TABLE people(
    id INT NOT NULL PRIMARY KEY,
    name VARCHAR2(50) 
);

这篇关于关于SQL语句中缺少左括号的令人困惑的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆