在Sql语句中,引用标识符主要是用于为数据库表明,字段名,索引名称的定义。常规标识符,不包含空格,不包含特殊字符。在引用时可直接使用,如果想在标识符定义中报刊空格等特殊字符,需要特殊处理。

MySql中,使用‘’,来处理特殊标识符。例如

create table Student{

  ID bigint not null,

  'Student Name' varchar(20)

}

在Sqlserver中使用[]来处理特殊标识符

create table Student{

  ID bigint not null,

  [Student Name] varchar(20)

}

相关文章:

  • 2022-01-13
  • 2021-09-21
猜你喜欢
  • 2022-02-23
  • 2021-06-30
  • 2021-12-12
  • 2022-12-23
  • 2022-01-01
  • 2022-12-23
相关资源
相似解决方案