Skip to main content
edited title
Link
ypercubeᵀᴹ
  • 98.6k
  • 13
  • 215
  • 305

Is there anyway to search PL/SQL reserved words with contains function in the Oracle?

Is there anyway to search PL/SQL reserved words with containsthe contains function in the Oracle?

I should explain more. We would like to search keywords such as "test for" or "test do" with containsthe contains or catsearch functioncatsearch functions from the user table in the Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" etc automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed as below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

Thanks

Is there anyway to search PL/SQL reserved words with contains function in the Oracle?

I should explain more. We would like to search keywords such as "test for" or "test do" with contains or catsearch function from user table in the Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" etc automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed as below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

Thanks

Is there anyway to search PL/SQL reserved words with the contains function in the Oracle?

We would like to search keywords such as "test for" or "test do" with the contains or catsearch functions from the user table in Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;
added 66 characters in body; edited tags
Source Link
user1822
user1822

Is there anyway to search PL/SQL reserved words with contains function in the Oracle?

I should explain more. We would like to search keywords such as "test for" or "test do" with contains or catsearch function from user table in the Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" etc automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed as below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

Thanks

Is there anyway to search PL/SQL reserved words with contains function in the Oracle?

I should explain more. We would like to search keywords such as "test for" or "test do" with contains or catsearch function from user table in the Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" etc automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed as below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

Thanks

Is there anyway to search PL/SQL reserved words with contains function in the Oracle?

I should explain more. We would like to search keywords such as "test for" or "test do" with contains or catsearch function from user table in the Oracle but the results only show for "test" and ignore those reserved words such as "do" or "for" etc automatically.

We assume we have a table called content in the users schema.

enter image description here

The queries are listed as below:

create table users.content (content_id int not null, content varchar(20) not null);

insert into users.content values (1, 'do something');

insert into users.content values (2, 'test it');

insert into users.content values (3, 'it has been tested');

insert into users.content values (4, 'will test it');

create index users.idx_content on users.content (content) indextype is ctxsys.context;

--drop index users.idx_content;

--drop table users.content;

select content_id, content from users.content where contains(content, 'do or test') > 0;

Thanks

added 545 characters in body
Source Link
Andy
  • 1
  • 2
Loading
added 594 characters in body
Source Link
Andy
  • 1
  • 2
Loading
added 594 characters in body
Source Link
Andy
  • 1
  • 2
Loading
added 266 characters in body
Source Link
Andy
  • 1
  • 2
Loading
Source Link
Andy
  • 1
  • 2
Loading