Solved

Arithmatic Operation within Select Query

Posted on 2004-09-08
3
273 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Supply Chain Event Management Supply chain visibility is the ability of a company to track its products and business processes in supply chain towards building operational excellence. The goal of supply chain visibility is to improve and strength…
Note: You must have administrative privileges in order to create/edit Sharing Rules. Salesforce.com (http://www.salesforce.com) (SFDC) is a cloud-based customer relationship management (CRM) system. It is a database most commonly used by sales an…

739 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