Thanks for you prompt response Tamas!<br><br>Well, after having used the ogrinfo tool (thanks for the hint - first time user of ogr/gdal you see), I tested the connection string mutliple times - and it turns out it was because I was using Initial Catalog parameter, instead of the Database parameter.<br>
<br>So - handy hint for the day - Don't use the Initial Catalog parameter in your SQL Server 2008 connection string with OGR. Use the Database parameter.<br><br>Cheers Tamas!<br><br><div class="gmail_quote">On Sun, Jan 23, 2011 at 11:05 PM, Tamas Szekeres <span dir="ltr"><<a href="mailto:szekerest@gmail.com">szekerest@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">Matthew,<br><br>Could you provide a sample data to reproduce this problem?<br>How the layer and the features are displayed by the ogrinfo command tool?<br>
<br>Best regards,<br><br>Tamas<br><br><br><br><br><div class="gmail_quote">
2011/1/23 Matthew Blackler <span dir="ltr"><<a href="mailto:matt@mattblackler.com" target="_blank">matt@mattblackler.com</a>></span><br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div class="h5">
Dear all,<br><br>I have downloaded v1.8.0 and am using .net CSharp bindings to connect into MSSQL such:<br><br>"MSSQL:SERVER=MATT-ACERPC\\SQLExpress;tables=categ(geom);Initial Catalog=Crown_GIS;Integrated Security=True";<br>
<br>I am able to connect and retrieve the driver ok. I am able to get the Layer "Categ" from the datasource, no problem. However, the extent of the layer, feature counts, and even the "get" of features using the nextfeature cursor fails to retrieve any features or information for me.<br clear="all">
<br>Any obvious pointers as to why iterating through a layer with a known number of features (4,000 ish) would result in returning nothing (i.e. no feature back from the getnextfeature), or why the extent of a layer would be reported as being 0,0,0,0?<br>
<br>Any help would be much appreciated. Looking forward to leveraging OGR to making our apps datasource independant, and throwing away the shackles of ArcObjects!<br><br>Thanks in advance,<br><br>Matthew Blackler<br><font color="#888888"><br>
-- <br><div>Email: <a href="mailto:matt@mattblackler.com" target="_blank">matt@mattblackler.com</a></div>
<div>Homepage: <a href="http://www.mattblackler.com/" target="_blank">http://www.mattblackler.com</a></div>
<div>Twitter: @mattblacklercom</div>
<div> </div><br>
</font><br></div></div>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br><div style="padding: 0px; margin-left: 0px; margin-top: 0px; overflow: hidden; word-wrap: break-word; color: black; font-size: 10px; text-align: left; line-height: 130%;">
</div>
</blockquote></div><br><br clear="all"><br>-- <br><div>Email: <a href="mailto:matt@mattblackler.com" target="_blank">matt@mattblackler.com</a></div>
<div>Homepage: <a href="http://www.mattblackler.com/" target="_blank">http://www.mattblackler.com</a></div>
<div>Twitter: @mattblacklercom</div>
<div> </div><br>