title: Firebird - serial field as in PGSQL?
body: <p>PGSQL supports "serial" field type, which is converted to:</p>
  
  <pre><code>colname integer DEFAULT nextval('tablename_colname_seq') NOT NULL
  </code></pre>
  
  <p>This makes the identifier generating very easy.</p>
  
  <p>In the Firebird I saw only trigger based solutions.</p>
  
  <p>Is it possible to use same solution in Firebird for avoid the trigger creation for each table?</p>
  
  <pre><code>colname integer DEFAULT gen_id(generator, 1)
  </code></pre>
  
  <p>I don't have installed Firebird version now to check it, but maybe somebody knows the answer.</p>
  
  <p>Or can I use "my function" for this?
  Pseudo:</p>
  
  <pre><code>create function mygenid(genname) returns integer
  begin
     return gen_id(genname);
  end;
  
  create table x(
     colname integer DEFAULT mygenid(generator, 1)
  </code></pre>