Re: Form field optional

Mike Aubury <[email protected]>
Newsgroups gmane.comp.lang.4gl.aubit.general
Message-ID <CAGAq4WH4=GbDjk4g4WgZiBTBxtZbFyQm+ETJty3WmDWPgSKU9g@mail.gmail.com>
Whats the definition of "product.mark" in the database ?

A simple test with formonly fields seems to work with a space :

tiny.per:

database formonly
screen
{
a [a]
}
attributes
a=formonly.a, autonext, include=(" ","a","b","c"), upshift;


tiny.4gl

main
define a char(1)
open form tiny from "tiny"
display form tiny
input a from a
end main



FWIW - in some (and only some) circumstances a "" is treated like NULL...




On 20 September 2013 15:15, Peter Müller <[email protected]> wrote:

> Hello,
>
> I'm converting Informix-4gl forms to Aubit. Some forms defines a field
> like this:
>
> a  = product.mark, autonext, include=(' ','B','N','D'), upshift;
>
> Using the form with Aubit4gl, it does'nt accept a blank field (like in old
> Informix-4gl environment).
>
> If I change the field definition to
>
> a  = product.mark, autonext, include=('','B','N','D'), upshift;
>
> it works.
>
> My question: is the zero-size string ('') functional equivalent to the
> one-space string (' ') ?
> Will the same data written to the DB ?
>
>
>
> ------------------------------------------------------------------------------
> LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
> 1,500+ hours of tutorials including VisualStudio 2012, Windows 8,
> SharePoint
> 2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack
> includes
> Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13.
> http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
> _______________________________________________
> Aubit4gl-discuss mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/aubit4gl-discuss
>
>

------------------------------------------------------------------------------
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk

_______________________________________________
Aubit4gl-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/aubit4gl-discuss
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.