|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Help in select Query
Hi Everyone,
I have a table with six date fields, when the user enters data in the form The database populates with TextBox values. Some fields could be null. My question is how to obtain the last NOT NULL Value from the table Row. For Example: Date1 Date2 Date 3 ......... ------ ------ ------- Value1 Value2 Value3 ......... if Value3 is NULL I want to get Value2. I'm not using Stored procedures. Thanks in advance |
|
#2
|
||||
|
||||
|
Hi,
I am not sure what you need, but you might be able to use something like this: Code:
select value1, isNull(field2,"Field1") as value2, isNull(field3,"Field2") as value3 from the Table hope this helps
__________________
Look! Its a ShemZilla ![]() ![]()
|
![]() |
| Viewing: ASP Free Forums > Database > Microsoft SQL Server > Help in select Query |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|