Solved

Arithmatic Operation within Select Query

Posted on 2004-09-08
3
268 Views
Last Modified: 2013-12-08
Hi abapers,
            I want to write a query like this.
 
data: pday type i. *(contains some day value).
*AB contains date value
Select AB from tabname where sy-datum - AB >= pday.

but system is not allowing me to subtract AB from sy-datum within the Select statement.

I don't want to write a subquery..

Please help me it is urgent..
0
Comment
Question by:yuve
3 Comments
 
LVL 1

Accepted Solution

by:
iamderek earned 125 total points
ID: 12065961
Rephase your code like this:

data: pday type i. *(contains some day value)
data pdate type d.

*AB contains date value
pdate = sy-datum - pday.
Select AB from tabname where AB <= pdate.

Derek
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Suggested Solutions

I showed you how to use console view (HERE (http://www.experts-exchange.com/articles/18379/Getting-Started-and-Using-the-Salesforce-com-Console.html)) -– but how do you set it up on the admin side of Salesforce? Note that you have to have Admin leve…
Read about achieving the basic levels of HRIS security in the workplace.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now