Re: mac.c

From: Larry Rosenman <ler(at)lerctr(dot)org>
To: Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu>
Cc: Larry Rosenman <ler(at)lerctr(dot)org>, pgsql-hackers(at)hub(dot)org
Subject: Re: mac.c
Date: 2000-08-07 10:25:57
Message-ID: 200008071025.e77APve28940@lerami.lerctr.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> > Since macaddr_manuf() will not be up to date, I'd say lets make
> > the new function macaddr_brand, and if someone wants to do the other
> > two, fine. I'd also doc the fact that macaddr_manuf() is deprecated, marked
> > for deletion one or two releases down the line (since the table will
> > no longer be updated, and is very much outdated).
>
> I've been thinking about this a bit, coincidentally while I've been
> working on the LIKE implementation for string comparisons.
>
> Why not implement like() and notlike() for macaddr data types which (if
> both args are macaddr) will compare on manufacturer's fields alone? That
> would seem to get all the functionality you might want.
>
> Example:
>
> SELECT * FROM machines where hwaddr LIKE
> (select id from MacIdCodes where manuf = 'Intel');
>
> or something like that.
>
> That would avoid ginning up something artificial like a macaddr with
> some fields zeroed out. We would still have an equality operator etc.
We still need to load a *TABLE* with a 3 byte hex number (at least) for
the OUI, and a text field for the actual manufacturer (see my posted
ouiparse.awk script). How do we store that 3 byte hex number (we don't have
a type that I'm aware of...)?

Don't get me wrong, I like your idea, but I'm not sure what it buys us after
the later suggestions I made of returning a half-zeroed mac...

Larry

>
> Comments?
>
> - Thomas

--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 (voice) Internet: ler(at)lerctr(dot)org
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749

In response to

  • Re: mac.c at 2000-08-07 07:22:44 from Thomas Lockhart

Responses

  • Re: mac.c at 2000-08-07 15:40:43 from Thomas Lockhart

Browse pgsql-hackers by date

  From Date Subject
Next Message Romanenko Mikhail 2000-08-07 11:04:27 Trouble with float4 after upgrading from 6.5.3 to 7.0.2
Previous Message Thomas Lockhart 2000-08-07 07:22:44 Re: mac.c