<br><br><div class="gmail_quote">On Dec 31, 2007 2:45 PM, Hans-Christoph Steiner &lt;<a href="mailto:hans@eds.org">hans@eds.org</a>&gt; wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div style="word-wrap:break-word">
<div><br></div><div>I took a look at it. &nbsp;It is nice to be able to handle the results right next to the query, but I find the send/receive as first argument confusing. &nbsp;I think the objects should use inlets and outlets and then people who want to use send/receive could it themselves. &nbsp;I can understand wanting to handle the queries separately from each other, but I think this can be accomplished using standard Pd message handling methods (lists, [route], etc). &nbsp;I&#39;ll try to come up with a working sketch soon. &nbsp;&nbsp;
</div></div></blockquote><div><br class="webkit-block-placeholder"></div><div>You can think of each send/receive SYMBOL attached to a database object as being a separate data channel. As we are restricted to one set of results in each database object, you can create multiple datapaths by using more than one database object, and giving it a different name. This way, two different query objects can make a request into the same database (using two different database objects opening the same database) at the same time. If these two queries were to send the requests to the same database object at the same time, they would interfere with each other, and would lose result sets.
</div><div><br class="webkit-block-placeholder"></div><div>Also, if we are going to make these connections between the objects as you suggest, just how would the database know which query object to send the result sets back to? I really don&#39;t like the idea of having all the data come out of the database object. That would force a user to build some sort of routing&nbsp;mechanism&nbsp;into their PD code, and in order to do that, you would have to write your SQL queries such that each was tagged with some symbol indicating its purpose.
</div><div>&nbsp;</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="word-wrap:break-word"><div>I think that the database object could have a data and a status outlet, like [hid]. &nbsp;Then the status info could all be handled centrally wherever the single sqlite object, then data would be routed to where it needs to go. &nbsp;Real world examples would be good to have now, I suppose we can look to see how people are using [pool] and PDContainer, or even [sqlsingle] and the Max MySQL object.
</div></div></blockquote><div><br class="webkit-block-placeholder"></div><div>I have no idea what &#39;hid&#39; does. So, I really don&#39;t understand what you want here. I will have to read the paper on it...</div><div>
<br class="webkit-block-placeholder"></div><div>As far as the &quot;status&quot; goes, I think that is something that should also be handled by the query object, as that is the object that actually generated the &quot;status&quot; message. The only status messages I see coming from the database object itself, are the ones dealing with the connection to the database (either by using &#39;open&#39; or &#39;connect&#39;).
</div><div><br class="webkit-block-placeholder"></div><div>And I still don&#39;t know why you want the data to come out of the database object. It just doesn&#39;t make any sense to have different query objects that send their queries to the database object, and then have those results come out of a central location. While I know that we could set it up so that each query result set would be tagged, and then route the data based on that, I just think it is better to have the data come out of the query object.
</div><div><br class="webkit-block-placeholder"></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="word-wrap:break-word"><div></div><div><br></div><div>
About &quot;addsemi&quot; I am starting to think that it should really only be there for specific circumstances and not for regular use. &nbsp;I think that if you execute a sql query by sending the data thru, it should just use whatever is in the SQL cold inlet buffer and add a semi-colon to it. &nbsp;Also, I think it would be good to avoid using semi-colons inside of the SQL in object boxes (
i.e. like in the [sql_query] example that I posted). &nbsp;This makes each sql_query a single SQL statement, which I think is quite clear, plus it could be tricky implementing the semi-colon handling.</div></div></blockquote><div>
<br class="webkit-block-placeholder"></div><div>I don&#39;t like the idea of automatically appending a semicolon. I think that everything that is in the SQL buffer should be put there by the user, and the external should do nothing to that buffer, except send it to the database. I also still see no restrictions on being able to send multiple SQL statements in the same packet, as that restriction does not exist in the standards. It is only a few databases that put this limitation on to their own operation to get around certain problems. Things like SQL injection, something I don&#39;t really see as being all that big a deal, it should be something left to either the database administrator to protect against, or the application developer. This is a framework we are creating, and we shouldn&#39;t be putting any limitations on how it can be used.
</div><div>&nbsp;</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="word-wrap:break-word"><div></div><div><br></div><div>Anyway, those are some rambling thoughts. It&#39;s great to see progress on this, hopefully we can get some people to try out the sketches to see what actually works.
</div><div></div></div></blockquote><div><br></div><div>Anyone with question, please feel free to ask.&nbsp;</div><div><br class="webkit-block-placeholder"></div><div><br class="webkit-block-placeholder"></div><div>Mike</div><div>
<br class="webkit-block-placeholder"></div></div>