2006 Nov 27 7:04 AM
Hi,
I have 2 db tables A and B. And I need to have a condition while joining these two tables. i have a field called date in A and date1 and date 2 in B.
The condition i would like to incorporate is A-date should lie between B-date1 and B-date2 (B-date1<A-date<B-date2).
I've tried out Maintenance Views and i can only give a comparative value in the selection conditions (say A-date eq sy-datum).
Can anyone suggest me how to go about this.
Thanks in advance...
Naren
Hi,
I have 2 db tables A and B. And I need to have a condition while joining these two tables. i have a field called date in A and date1 and date 2 in B.
The condition i would like to incorporate is A-date should lie between B-date1 and B-date2 (B-date1<A-date<B-date2).
I've tried out Maintenance Views and i can only give a comparative value in the selection conditions (say A-date eq sy-datum).
Can anyone suggest me how to go about this.
Thanks in advance...
Naren
2006 Nov 27 7:12 AM
use inner join so that u can get the all the fields from left table and the common fields from right table
2006 Nov 27 7:19 AM
Hi
I don't believe you can create a view like that.
U should explain what you need to do.
Max
2006 Nov 27 8:12 AM
The exact scenario is, i have 3 DB tables and I've created a view with the join conditions. I need to incorporate a condition(as I've mentioned in my query)on 2 of the DB tables, which I couldn't do. Hope u understood the requirement.
so in total if I go to the View and see the contents i need to have the entries which match the exact requirement.
the alternate solution would be to create a batch program which would have the conditions that couldn't be met during the build and append the required entries to another DB table and so if I go to the new DB table i can have all the required entries.
But I do want to have this alternate solution only if nothing else can be done.
2006 Nov 27 8:33 AM
hi
good
go through these links which ll gie you idea about view with join statement.
http://dev.mysql.com/doc/maxdb/en/6d/117c44d14811d2a97400a0c9449261/content.htm
thanks
mrutyun^
2006 Nov 27 7:22 AM
hi,
why do n't u sue FOR ALL ENTRIES..statement here ..?
Regds,
vinsa.R
2008 Jan 15 3:35 AM
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |