Portal Engine Questions on portal engine and web parts.
Version 4.x > Portal Engine > Custom table - Drop down field - Allow empty? View modes: 
User avatar
Member
Member
dbircsak - 3/4/2009 1:53:26 PM
   
Custom table - Drop down field - Allow empty?
I noticed when I have a drop down field that has Allow empty equal to true, that the drop down still displays all values returned from the SQL select statement?

Perhaps I could do:
select countryid,countryname from cms_country
union select null,'(select one)'
order by countryname asc

...i.e. add the blank

Or maybe a feature could be added to have drop down display "(select one)" always at top if "Allow empty" is set to true

User avatar
Kentico Developer
Kentico Developer
kentico_helenag - 3/10/2009 9:34:08 AM
   
RE:Custom table - Drop down field - Allow empty?
Hello,

Allowing empty value does not mean that it adds a blank option. It means that there may be a null value in the database. You would need to ensure the “blank value” by yourself. You could for example add a new raw directly in the CMS_Country table.

Best regards,
Helena Grulichova