如何创建姓氏以'S'开头的oracle视图?

时间:2019-12-03 11:45:28

标签: oracle

我正在尝试创建一个视图,该视图允许我根据以下内容选择所有姓氏以“ S”开头的用户:

CREATE TABLE cteam_Users(
    UserLastName  VARCHAR2(50) NOT NULL,
    );


INSERT INTO cteam_Users
    (  UserLastName,)
    VALUES ('Sam');

INSERT INTO cteam_Users
    (  UserLastName,)
    VALUES ('Tam');

Create view cteam_V1 As 
SELECT UserLastName From cteam_Users 
Where UserLastName = 's%'; 

SELECT  * FROM cteam_V1;

1 个答案:

答案 0 :(得分:0)

您将需要使用map.removeLayer(infill)运算符,如下所示:

like

我已使用Create view cteam_V1 As SELECT UserLastName From cteam_Users Where lower(UserLastName) like 's%'; 函数进行不区分大小写的匹配。