Bit of a hack, but it does work...thx!  I wonder whether we can add our
own syntax?  I'd love to create, FIRSTOF() to make this a little clearer
(and less hacky).

Thanks,

Shawn Wildermuth
[EMAIL PROTECTED]

> -----Original Message-----
> From: dotnet discussion [mailto:[EMAIL PROTECTED]]
> On Behalf Of Marcelinus Gozali
> Sent: Monday, April 22, 2002 3:03 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [DOTNET] DataColumn.Expression Syntax and Child.XXX
>
>
> Try this one:
>
> invoiceItemTable.Columns.Add("Desc",
> typeof(string),"MAX(Child.Description)");
>
> > -----Original Message-----
> > From: dotnet discussion [mailto:[EMAIL PROTECTED]]
> > On Behalf Of Shawn Wildermuth
> > Sent: Monday, April 22, 2002 1:08 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [DOTNET] DataColumn.Expression Syntax and Child.XXX
> >
> >
> > Sorry, I didn't give any examples of what worked and didn't work:
> >
> > Doesn't Works:
> > invoiceItemTable.Columns.Add("Price", typeof(float), "Child.Price");
> >
> > Works:
> > invoiceItemTable.Columns.Add("Price", typeof(float),
> > "Avg(Child.Price)");
> >
> > This works because it is a one-to-one relationship and it
> is a number.
> > I haven't found any hacks to make it work for strings.   What
> > I want is:
> >
> > invoiceItemTable.Columns.Add("Desc", typeof(string),
> > "Child.Description");
> >
> > Any ideas?
> >
> > Thanks,
> >
> > Shawn Wildermuth
> > [EMAIL PROTECTED]
>
> You can read messages from the DOTNET archive, unsubscribe
> from DOTNET, or subscribe to other DevelopMentor lists at
> http://discuss.develop.com.
>

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to