‎2007 Apr 24 3:58 PM
Hi All,
I have custom table with field that contains the * (star) values . ie
ABC*123
AB*1234
A*12345
A%12345
a&12345
I need to get values of all * entries using a select statement.
I don't need to select all and loop thru and filter it out
Any suggestions ?
Thanks
aRs
‎2007 Apr 24 4:01 PM
you can try using the pattern search ie
select * from <dbtab> into table <itab>
where <fld> like '%*%'.
~Suresh
‎2007 Apr 24 4:06 PM
Here you go,
for example,
SELECT... WHERE CITY LIKE '%town%'.
This condition is true if the column CITY contains a string containing the pattern town.
Regards,
Bhasha
‎2007 Apr 24 4:07 PM
Hello aRs,
U can select like this.
data: var.
var = '*'.
select * from ztable where field like var.Regards,
Vasanth
‎2007 Apr 24 4:08 PM
Try this but not sure...
select <field> from table where field like '%*%'.
Thanks,
SKJ
‎2007 Apr 24 4:13 PM
Hi,
You can build a wildcard ranges and please try something like this.
r_wildcard-sign = 'I'.
r_wildcard-option = 'CP'.
r_wildcard-low = 'B*'.
append r_wildcard.
r_wildcard-sign = 'I'.
r_wildcard-option = 'CP'.
r_wildcard-low = '*B*'.
append r_wildcard.
select * from mara
into table gt_mara_b
where mtart = 'YSAB'
and matnr in r_wildcard.
Regards,
Ferry Lianto