LIKE operator for Condition object
I want to use pattern matching in a Condition that is applied to a DBDataSource Query.
Is this going to be available in the 2004 SDK?
(It would be much easier if we could just add our own WHERE clause as text.)
Hi,
I try with this operation code over MSSQL Server:
condicion.Operation = co_GRATER_EQUAL + co_LESS_EQUAL
and the operation is: like [CondVal]%
Best regards.
Similar Messages
-
hi Experts,
while running SQL Query i am getting an error as
The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE operator. for the query
select T1. Dscription,T1.docEntry,T1.Quantity,T1.Price ,
T2.LineText
from OQUT T0 INNER JOIN QUT1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN
QUT10 T2 ON T1.DocEntry = T2.DocEntry where T1.DocEntry='590'
group by T1. Dscription,T1.docEntry,T1.Quantity,T1.Price
,T2.LineText
how to resolve the issueDear Meghanath,
Please use the following query, Hope your purpose will serve.
select T1. Dscription,T1.docEntry,T1.Quantity,T1.Price ,
CAST(T2.LineText as nvarchar (MAX))[LineText]
from OQUT T0 INNER JOIN QUT1 T1 ON T0.DocEntry = T1.DocEntry LEFT OUTER JOIN
QUT10 T2 ON T1.DocEntry = T2.DocEntry --where T1.DocEntry='590'
group by T1. Dscription,T1.docEntry,T1.Quantity,T1.Price
,CAST(T2.LineText as nvarchar (MAX))
Regards,
Amit -
Using Like Operator For Parameter Fields
Hi All,
I have been figuring around this for few days, appreciated anyone know this could assit me
I have a report which having a mobile no parameter fields.
In my database, my mobile no was not a clean entry.
For eg, a standard mobile number from Malaysia was 60126143331.
1) 60 - indicate country code (MYS)
2) 12 - indicate mobile operator
3) 6143331 - indicate phone number
Usually, peoples will entry it as 6012-6143331 or 012-6143331 or 0126143331 or 60126143331. In my CR report, i have a static mobile no selection. Currently, my filter selection will be as below:
{pax.mobile_no} = {?p_mobileno}
any possible to change it to like? meaning to say, if user enter 012-6143331 it will know that this was 6012-6143331 and the records will be selected into the report.
Appreciated anyone know this could assits.
Thanks in advance.
Regards,
CKHi,
tq for ur prompt reply.
D value in my database r not fix, some mobile no could b 7 digits some could b up to 12 digits. But I jz want user to enter mobile no in 10 digits only. Example, mobile no in db wa 60126661233. However, user input in parameter selection could only 0126661233 without 6. In some situation if mobile no in db was 6012-6661233, user input willb only 0126661233 n this input will b match with data in db using like operator.
I m wondering can this b archieve in cr?
Tq
regards,
ck -
SPAU-like functionality for custom objects - Z* or Y* Objects?
Hello Experts,
My scenario is like below:
Assume that my SAP System is DEV1 and it is of SAP 4.6X version. I have imported Program ZPGMA from foreign system DEV2. And are moved to the Production system PROD1. Now there are some corrections did in program ZPGMA in DEV1 system either by using modification assistant or by turning Modifications Assistant Off. And then moved to PROD1.
Now we are going for Upgradation from 4.6X system to ECC 6.0.
Now, i need to get the list of programs that have original system as DEV2 but are modified in DEV1.
In brief, i am looking for some functionality similar to SPAU which would work for Custom objects (Z* or Y* Objects).
Thanks and Best Regards,
SureshHi Suresh,
There is not any functionality like SPAU to find these kind of program.But if you want to find your DEV2 programs moved and modified in DEV1, just go in table TADIR and find source system field ( SRCSYSTEM ) as DEV2 .
You will get list of program moved in DEV1.
Regards
NImesh S. Patel -
Like operator for sharepoint ssrs
Hi,
i ve got a multiiple instructor coulmn like
i ve written experssion like = Join(Parameters!Instructor.Label,",") Like "*" & Fields!InstructorName.Value & "*"
boolean
value=true
but Please see the below image
it is displaying wrong instructor results
Any Suggestions?
Thanks Manohara RHi,
As this question is more relate to SQL Server, I suggest you post it to SQL Server Forum, you will get more help
and confirm answers from there.
http://social.technet.microsoft.com/Forums/en-US/home?forum=sqlreportingservices
Best regards
Dennis Guo
TechNet Community Support -
Exclude "*" in Like operator
Hi All,
I am trying to use like operator for an output data which has "*" appended at the end.
For example, following is the Place_ID which i have data in a table
12190101*
12349021
12347284
12598992*
When i provide search criteria as "1234" in my application, my query is making the condition as
Place_ID Like "1234%"
But unfortunately it is giving 4 rows as output which is not considering the values which is appended with '*".
I tried making use of the following, but still this is not working.
Place_ID Like "1234%" ESCAPE '*'
Can someone suggest me where i am doing wrong.
Thanks,
PrakashPrakash wrote:
But unfortunately it is giving 4 rows as output which is not considering the values which is appended with '*".It is not clear what output you expect. But one thing is for sure: condition Place_ID Like 11234%' can't return 4 rows:
{code}
with data as(
select '12190101*' place_id from dual union all
select '12349021' from dual union all
select '12347284' from dual union all
select '12598992*' from dual
select place_id
from data
where place_id like '1234%'
PLACE_ID
12349021
12347284
SQL>
{code}
So post desired results.
SY. -
Like operator issue with on Number column
Hi,
Query with like operator for Example: " where RATE LIKE ('%2%')"
the result of the query returns rows which contains "2" as part of field value along with few rows which are updated recently, but do not contain 2 in that row.
In the table data type of COLUMN is Number, no precision.
Pls let me know if any one knows about this.
--satya.Can you please post the result of the query you are using?
Regards -
Hi All,
we are using like operator for search functionality (oracle 10G).
could any one help me in handling null, when we use like operator.
Ex:
select empno,ename,d.deptno
from emp e, dept d
where e.deptno = d.deptno
and e.ename like '%JO%';
we have a text box in the front end to key in employee name (ename) or part of ename. when user doesnt use this option, he leaves it blank.
so In the above query, if ename is null then my query fails.
could anybody help me out in handling this scenario.
My query should still give me all the employee ids, if the ename is blank.
using dynamic sql is not advisable.
Thanks
ManjuSomething like this ->
satyaki>select *
2 from v$version;
BANNER
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
PL/SQL Release 10.2.0.3.0 - Production
CORE 10.2.0.3.0 Production
TNS for 32-bit Windows: Version 10.2.0.3.0 - Production
NLSRTL Version 10.2.0.3.0 - Production
Elapsed: 00:00:00.26
satyaki>
satyaki>
satyaki>select *
2 from emp
3 where upper(ename) like nvl('%'||upper('&str')||'%',upper(ename));
Enter value for str:
old 3: where upper(ename) like nvl('%'||upper('&str')||'%',upper(ename))
new 3: where upper(ename) like nvl('%'||upper('')||'%',upper(ename))
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
9999 SATYAKI SLS 7698 02-NOV-08 55000 3455 10
7777 SOURAV SLS 14-SEP-08 45000 3400 10
7521 WARD SALESMAN 7698 22-FEB-81 1250 500 30
7566 JONES MANAGER 7839 02-APR-81 2975 20
7654 MARTIN SALESMAN 7698 28-SEP-81 1250 1400 30
7698 BLAKE MANAGER 7839 01-MAY-81 2850 30
7782 CLARK MANAGER 7839 09-JUN-81 4450 10
7788 SCOTT ANALYST 7566 19-APR-87 3000 20
7839 KING PRESIDENT 17-NOV-81 7000 10
7844 TURNER SALESMAN 7698 08-SEP-81 1500 0 30
7876 ADAMS CLERK 7788 23-MAY-87 1100 20
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
7900 JAMES CLERK 7698 03-DEC-81 950 30
7902 FORD ANALYST 7566 03-DEC-81 3000 20
13 rows selected.
Elapsed: 00:00:00.02
satyaki>
satyaki>/
Enter value for str: sa
old 3: where upper(ename) like nvl('%'||upper('&str')||'%',upper(ename))
new 3: where upper(ename) like nvl('%'||upper('sa')||'%',upper(ename))
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
9999 SATYAKI SLS 7698 02-NOV-08 55000 3455 10
Elapsed: 00:00:00.08Regards.
Satyaki De. -
Like operator(NonCase sensitive)
Hi,
Every Body, I need query that use the like operator for pattern matching but that pattern
matching should be Non case sensitive is there any keywords that make like operater NonCase
Sensitive,
query like is ,
select * from table_name where column_name like 'matchingword';
that is in the Oracle 9i database..
please kindly help me ,
Regard's
Paritosh tomar
Edited by: user632002 on Sep 12, 2008 3:03 AMhb venki wrote:
Hi,
Try like this but i never like that of function,
select from table_name where UPPER(column_name) like UPPER(LOWER('mAtchINgwoRd'));*
hb venkiThe LOWER function there is not needed *{:-) -
Mass Maintenance for Conditions and copying them to other system
Hello folks,
1)I'm wondering wether there's the possility to mass-maintain conditions.
So far I've been doing this manually in ...
MASTER DATA > PRICES AND CONDITIONS > TX "Maintain conditions"
Does anyone have any idea about this?
2)There is report for transporting marketing attributes from, e.g., test- to productive System. Is there anything like this for conditions as well?
Thank you for your ideas!
Greetings from Hamburg!
Hauke BöhmerHi Yacoub
Please see if you setup standard t-code MASS for sales prices maintaince in a mass way. -
Like operator not passed to database for nvarchar(max)
From Crystal Reports 2008 I need to do a keyword search against a data type of nvarchar(max).
I am using the LIKE operator in my record selection formula.
When I do a SHOW QUERY the LIKE condition is omitted from the where clause.
This makes the report run so slow it is useless.
How can I do a keyword search against an nvarchar(max) data type?
Thanks,
Larry
CR Developer 12.2.0.290, Product type: Full
SQL Server 2008 r2Sorry it wasn't clear what you are doing or why. I assumed you were using the LIKE in the record selection formula to filter on fields like CustomerID etc. which can be passed to the server. You want to filter based on the text in a Description type field field.
Yes that is going to be very slow having Crystal do it client side, means all of the data will be sent to the local work station and then on the second pass CR will start filtering.
You could try using a Command Object to use as the data source, CR should simply pass what ever SQL you type in. Copy your existing SQL and then create a new report and use a Command object and paste in the SQL, edit it to include the LIKE operator and see it that works for you.
Another option is to use a Stored Procedure with a parameter to do the searching, that will force it to do it Server side. DB servers will aways be more efficient at processing filters that ce will be.
When viewing the report can you not use the Search window, although that is after the fact so it too would mean all data has to come down first...?
Basically what is happening is CR is testing every word in the nvarchar field, CR isn't very optimized to do that kind of filtering client side and because it's more complex SQL we won't generate the proper syntax to pass it to the server. Also, Cr supports so many data sources and to build that logic into the basic report designer is very complex and not efficient, there are various DB tools that can do that kind of work and CR can connect to them, Universes, Data Integrator etc., those tools are designed to do this type of complex SQL generation.
Thank you
Don
PS - If Jason sees this thread he is a SQL guru and may have some suggestion for you also.
Edited by: Don Williams on Jun 22, 2011 11:17 AM -
What is the conditional operator for AND, OR .....?
what is the conditional operator for AND, OR .....? in ABAP language...
AND, OR .. & is not accepting or recognising.
Is these feature available in abap ??? if yes, how to use?
thanks...
shivaHi,
Conditional operator for AND and OR are same AND and OR.
A logical expression consists of comparisons (see expressions 1 to 4 below) and/or selection criteria checks (expression 5) using the operators AND, OR and NOT , as well as the parentheses " (" and ")".
The individual operators, parentheses, values and fields must be separated by blanks:
Incorrect:
f1 = f2 AND (f3 = f4).
Correct:
f1 = f2 AND ( f3 = f4 ).
NOT takes priority over AND, while AND in turn takes priority over OR:
NOT f1 = f2 OR f3 = f4 AND f5 = f6
thus corresponds to
( NOT ( f1 = f2 ) ) OR ( f3 = f4 AND f5 = f6 )
The selection criteria comparisons or checks are processed from left to right. If evaluation of a comparison or check proves part of an expression to be true or false, the remaining comparisons or checks in the expression are not performed.
All data objects that can be converted among each other can be used as operands for logical expressions.
Check if u are using the AND or OR operator this way.
IF f1 AND f2.
ENDIF.
In this case it will throw error. Here it act as relational operator.
Regards,
Prakash -
I am trying like **** to download itunes 10.6.3 (64 bit - Windows 7) and I keep getting "the installer was interrupted before the requested operations for iTunes could be completed. Your systems has not been modified." I NEED HELP, PLEASE!
I got it figured out myself... yaaaaay for me!
-
LIKE operator- change symbol for [all characters]
I have an input parameter which contains symbols "*" (star symbol), example:
i_search_par := 'country * street';
I gonna do query:
select * from SearchTable
where col1 like i_search_par;
I want that the "*" would act the same way as "%"-symbol in LIKE operator.
So i want that query would return such results:
'country 1 street'
'country 200 street'
and so on.
What is the better way to achieve this, that "*" is going to be interpreted as a "any number of any symbols"?
Maybe i can say something like:
SET SESSION ANYCHAR SYMBOL = "*".
And after doing that Oracle understands in LIKE operators that star-symbol is like i want?
Or should i really do string replacement by replacing ""%" to "*" in "i_search_par" and in other 30 such varaibles?Hi,
Sorry, I don't think there's any way to tell LIKE to use different wildcards.
CharlesRoos wrote:
I have ca 30 input parameters:
i_search_par1 := 'country * street';
i_search_par2 := 'country * street';
i_search_par30 := 'country * street';Wouldn't it be just as easy to say:
i_search_par1 := 'country % street';
i_search_par2 := 'country % street';
i_search_par30 := 'country % street';?
>
And i will use them all like this:
select * from T
where Col1 like i_search_par1
and Col2 like i_search_par2
and
Col30 like i_search_par30You could write a very simple user-defined function. It would be slower, but the query would be a tiny bit simpler:
select * from T
where my_like (Col1, i_search_par1) = 1
and my_like (Col2, i_search_par2) = 1
and my_like (Col30, i_search_par30) = 1
Then you suggest that i sgould do string replacement 30 times for each parameter?Do you mean 1 time for each parameter, or 30 times altogether? Yes.
Isn't there better solution?
Maybe database has instruction that changes interpetation of symbol "*" into "%".It would be handy, but I don't think such a thing exists. -
(+) operator for a between condition
When i write this query in the sql prompt, getting an error "Invalid relational operator".
But when i write the same query in the report bulider , there is no error.
(but data is not selected as required)
Is this query correct? Can we write (+) operator for between conditions
select tab1.col1,
tab2.col1
tab1.col2,
tab2.col2
from emp tab1,emp tab2,table3
where tab2.col1(+) = tab1.col1
and tab2.col2(+) = tab1.col2
and tab1.col2(+) between TO_DATE('11/10/20060601','DD/MM/YYYYHH24MI')
AND TO_DATE('11/10/20061400','DD/MM/YYYYHH24MI')
Thanks in advance
ChettarjeeGet rid of the (+) before the between.. Only use (+) when outer joining tables.
This statement below is not outer joining a table with a table..
and tab1.col2(+) between TO_DATE('11/10/20060601','DD/MM/YYYYHH24MI')
AND TO_DATE('11/10/20061400','DD/MM/YYYYHH24MI')If you are trying to say tab1.col2 must be between two dates or it can be null then do this..
"(and tab1.col2 between TO_DATE('11/10/20060601','DD/MM/YYYYHH24MI')
AND TO_DATE('11/10/20061400','DD/MM/YYYYHH24MI') or tab1.col2 is null)"
The above where clause is just a guess of what you may be trying to do with the (+) before the between.
Message was edited by:
Mark Reichman
Maybe you are looking for
-
IMac Windows 7 - Won't Start Up - i/o error 0xc00000e9
Hello Bootcamp Community, About a month ago I was working with both OSX 10.6.8 and Windows 7. After moving from OSX to to Windows 7 I started getting a message saying that a drive connected to the machine was causing and i/o error 0xc00000e9. I unpl
-
my iphone 4s is not able to sync since the latest update to itunes.
-
HP Officejet 5610 all in one "Door Open" error msg
HP Officejet 5610 all in one printer: "Door Open" error msg when door is closed. Can't print.
-
Hi, I am creating sop from forecast. I am doing the following steps. Please tell me whether I am right or not. In the first month I have maintained the historical consumption values for materials in MM02 under total consumption. I created sop for the
-
Change margins + object move with margins
Hello! We have a catalogue with 300+ pages! Margins size for that catalogue are: Top: 18 mm Bottom: 18 mm Indise: 12,7mm Outside: 12.7 mm Margins Inside and outside must to be change to 20 and 15 mm After i change the margins, the objects(incl. conte