Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL Server Select Statement
Message
From
21/07/2005 11:21:34
Stephen Hunt
Admit Computer Services Inc.
Farmingdale, New York, United States
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
01034265
Message ID:
01034682
Views:
26
Ok this is what I need to do

I have a payments table where I want to select a payment date range and select for a specific judgecode. The judge code could come from up to 5 different tables here are the table sturctures and some values

payments
py_paydate py_module pkeyident
'01/01/2005' 'MV' '1'
'02/01/2005' 'SC' '2'
'04/01/2005' 'CRM' '3'
'04/01/2005' 'LL' '4'
'01/01/2005' 'CV' '5'

MV
keyident mv_judge
'1' 'MMM'

SC
keyident sc_judge
'2' 'LLL'

LL
keyident ll_judge
'4' 'LLL'

CRM
keyident crm_judge
'3' 'AAA'

CV
keyident sc_judge
'5' 'LLL'

where py_module determines which module the payment came from

so in my select statement I want to select all payments
from 01/01/2005 - 12/31/2005 with judge code ='LLL'

Hope this helps explain what I am trying to do a little better !
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform