Hi Bogdan,<br><br>Let&#39;s suppose that we have 2 tables, one for domains and other for users but with the domain field the foreign key from domains table. Also I have in the users table the bit type fields &quot;local&quot;, &quot;mobile&quot;...<br>
In this case our output from the created view &quot;grp&quot; will be<br><br>username  domain    grp     last_modified<br>xxyy10    sip1.abcd.efg    international    1900-01-01 00:00:01<br>xxyy10    sip1.abcd.efg    local    1900-01-01 00:00:01<br>
xxyy10    sip1.abcd.efg    mobile    1900-01-01 00:00:01<br>xxyy10    sip1.abcd.efg    national    1900-01-01 00:00:01<br><br>So, each table has a primary key, but the &quot;result&quot; - not. Can I use this result for group module? Or, I should generate also a primary key?<br>
<br>Best regards,<br>Oleg<br><br><br><div class="gmail_quote">On Tue, Feb 2, 2010 at 4:13 PM, Bogdan-Andrei Iancu <span dir="ltr">&lt;<a href="mailto:bogdan@voice-system.ro">bogdan@voice-system.ro</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi Oleg,<br>
<br>
most of the &quot;id&quot; columns are not used by opensips (neither written, nor<br>
read) - but they are used as primary keys.<br>
<br>
So, you can remove the columns, but be sure in setting another primary<br>
key for the tables.<br>
<br>
Regards,<br>
Bogdan<br>
<div><div></div><div class="h5"><br>
Oleg Burlacu wrote:<br>
&gt; Hi!<br>
&gt; I&#39;m planning to migrate from fixed database tables to views.<br>
&gt; But I have a touble to generate the auto increment field - &quot;id&quot;.<br>
&gt; Can opensips operate with tables without the &quot;id&quot; filed?<br>
&gt;<br>
&gt; Thanks,<br>
&gt; Oleg<br>
</div></div>&gt; ------------------------------------------------------------------------<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; Users mailing list<br>
&gt; <a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
&gt; <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
&gt;<br>
<br>
<br>
--<br>
Bogdan-Andrei Iancu<br>
<a href="http://www.voice-system.ro" target="_blank">www.voice-system.ro</a><br>
<br>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div><br>