10-08-2008 9:55 PM
account no. in database is stored as 0001000085 the domain is defined as characters with limit 10 .
but this value is received as input and it is displayed as IEQ0001000.
so i shifted leading zeros,
after shifting leading zeros its displayed as IEQ0001000070
anyways im using this value in a select query and query doesnt work becuse it will accept only '0001000070' .
only when i hardcode '0001000070' . in where cluase the wuery works,,even if i pass '1000070' query doesn't work..
pls note : the input is a range so i can't hard code 1 value .
any suggestions ,Thanks.
10-08-2008 10:02 PM
What do you mean by input? someone enters the number?
If it's a range use IN. It should work
10-08-2008 10:30 PM
10-08-2008 10:13 PM
how do you define the select option. show your declaration and related code...?
10-08-2008 10:33 PM
select options : account for tablename-fieldaccount.
i'm using this value in select query.
select * from table into itab where fieldaccount IN account.
here as i said earlier in table ,domain is char with limit 10 .
10-08-2008 10:48 PM
It looks like you are treating a SELECT-OPTION like a PARAMETER in a WHERE clause of a SELECT statement.
Rob
10-08-2008 11:31 PM
Rob,
If so,
what would be correct way to pass that value in where clause .
Thanks,
Nt. :
select-options : account for table-field.
10-09-2008 2:07 AM
Hi Sona,
I hope i understood your question.
If you want the inputs with leading ZEROs, then just declare it as NUMC or N type variable.
It will prefixes the ZEROs.
Else,
you can use,
CONVERSION_EXIT_ALPHA_INPUT
This function module will prefix the ZEROs.
In SLEECT OPTION, there will be four fields namely SIGN, OPTION, LOW, HIGH.
SIGN contains the INCLUDE or EXCLUDE specification i.e. 'I' or 'E'.
OPTION contains the LOGICAL RELATIONAL OPERATOR i.e. EQ, NE, GT,GE...
We want these two fields exclusively while SELECT-OPTIONs used in SELECT query.
LOW has our lower limit of the input.
HIGH has our upper limit of the input.
Regards,
R.Nagarajan.
-
We can -
10-09-2008 2:09 AM
Your SELECT looks OK, but it does look like something else is going on.
Rob
10-09-2008 3:04 AM
select-options : account for table-field.
what is the table and what is the field in the above statement. is it some secret code..? if you code it just tell the fieldname?
10-09-2008 3:30 AM
Thanks all.
Anyhow I'm done with this now.have fixed it myself.
Though the query with IN didn't work for me, i introduced a loop statement (since the Select-options variable is treated like an internal table.)
Voila! The same query worked fine.
It looks like common using the query with IN after select-options but it didnt work for me.in this case.mm.
10-09-2008 6:02 PM
10-09-2008 8:44 PM
closing thraed.
not sure if there's any other option /button to close the thread.
10-09-2008 10:12 PM
At the top of the thread there is a link that allows you to close the thread (mark as answered - even though it isn't). You can also assign p0ints to any answer that you feel helped.
Rob