<div dir="ltr">I should also mention, I&#39;m using this with a postgres db, so the schema install would be from the postgres definition/scripts.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Oct 25, 2013 at 12:50 PM, Bobby Smith <span dir="ltr">&lt;<a href="mailto:bobby.smith@gmail.com" target="_blank">bobby.smith@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Greetings,</div><div><br>I&#39;m trying to migrate an opensips 1.7 install to 1.9.  In the process, I noticed the drouting tables have changed a good bit.</div>
<div><br></div>After the schema was changed in 1.8 for the drouting module, this is a description of the new dr_gateways table (at the bottom).<div>
<br>My question is:  there is now a &quot;id&quot; column, which is what i&#39;d expect, and a gwid column, which is a varchar type that&#39;s not a sequence, not unique, but cannot be null.  What is this column used for?<br>

<br>I noticed opensips 1.7, there is just a gwid column, which is an int with a sequence, which is what I expected.  Is this just a way to carry that over with a db migration to 1.8 without having collisions on the sequence?  So that new id&#39;s are generated, leaving this column essentially deprecated?<br>

<br>If so, why make it not null?<br><div><div><br></div><div><div>opensips=# \d dr_gateways;</div><div>                                   Table &quot;public.dr_gateways&quot;</div><div>   Column    |          Type          |                        Modifiers                         </div>

<div>-------------+------------------------+----------------------------------------------------------</div><div> id          | integer                | not null default nextval(&#39;dr_gateways_id_seq&#39;::regclass)</div>

<div> gwid        | character varying(64)  | not null</div><div> type        | integer                | not null default 0</div><div> address     | character varying(128) | not null</div><div> strip       | integer                | not null default 0</div>

<div> pri_prefix  | character varying(16)  | default NULL::character varying</div><div> attrs       | character varying(255) | default NULL::character varying</div><div> probe_mode  | integer                | not null default 0</div>

<div> description | character varying(128) | not null default &#39;&#39;::character varying</div><div>Indexes:</div><div>    &quot;dr_gateways_pkey&quot; PRIMARY KEY, btree (id)</div><div>    &quot;dr_gateways_dr_gw_idx&quot; UNIQUE, btree (gwid)</div>

</div><div><br></div><div>Thanks,</div><div><br></div></div></div></div>
</blockquote></div><br></div>