Subject RE: [firebird-support] Design Question: Storing and using generic text "tags"
Author Jarrod Hollingworth
Hi Daniel,

> I'd imagine a design like this:

Thank you for your input on this.

> create table tags
> (
> constraint un_tags_name unique(name)

In a multi-user environment I'll have to be prepared for this to fail (two users added the same new tag at the same time).

> create procedure find_tag(name varchar(255)) returns (id_tag
> integer) as
> begin
> select id from tags where name=upper(:name) into :id_tag;
> if (:id_tag is not null) then

I think you meant "if (:id_tag is null) then".

Thanks again.

Regards,

Jarrod Hollingworth
Complete Time Tracking
http://www.complete-time-tracking.com/