navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

How to assign blank value to the form field to check in database

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> How to assign blank value to the form field to check in database
Page: [1]
 
shilpij

 

Posts: 1
Joined: 6/4/2004
Status: offline

 
How to assign blank value to the form field to check in... - 6/7/2004 5:41:27   
I have a form field with drop down list. I should be able to assign a blank value to that form field in case 'ALL' is selected for that list. The name of the field is categories. The corresponding column in the database is ty_opr_cod. When 'All' is selected, then I should get all the ty_opr_cod in my result.

My code reads
<%
If Request.Form("ty_opr_cod") = "ALL" Then
ty_opr_cod=""
Else
ty_opr_cod="="&Request.Form("ty_opr_cod")
End If
%>

and my where clause reads
select * from xdummy where ty_opr_cod LIKE '%::ty_opr_cod::%'

WHen a particular value is given, the result is correct.
Page:   [1]

All Forums >> Web Development >> ASP and Database >> How to assign blank value to the form field to check in database
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts