Re: [MI-L] SQL Querying

2006-09-19 Thread Andy Harfoot
Hi Andrew, The SQL Select syntax is: select table1.IDcol , table2.IDcol , areaoverlap(table1.obj,table2.obj) from table1,table2 where table1.obj intersects table2.obj Note that the area returned will be in Mapinfo's current area units, so you might want to set these by running the 'Set Area

RE: [MI-L] SQL Querying

2006-09-18 Thread Peter Horsbøll Møller
Andrew, This should do it: Select TABLE1.NAME , CartesianArea(Overlap( TABLE1.OBJ, TABLE2.OBJ), sq m) AREA_SQM FromTABLE1, TABLE2 Where TABLE1.OBJ Intersects TABLE2.OBJ Peter Horsbøll Møller GIS Developer, MTM Geographical Information IT COWI

RE: [MI-L] SQL Querying

2006-08-15 Thread Spencer Simpson
Select areaname, sum(int(mycode=code1))Code1, sum(int(mycode=code2))Code2, ... From mybigtab Group by areaname Hope this helps Spencer -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Tracey Sent: Tuesday, August 15, 2006 11:51 AM To:

RE: [MI-L] SQL Querying

2006-05-02 Thread Nabors, Steve
Andrew, There is probably a procedural/manual way of doing this via a series of manual selections using geographic functions in your selections. A better was is via mapbasic. Here is some mapbasic to get you started if mapbasic is an option for you. Disclaimer:I just typed it out and have not run

RE: MI-L SQL Querying

2005-10-10 Thread Terry McDonnell
Andrew Select Postcode from Table 1 where PostCode not in ( select Postcode from Table2) HTH Terry McDonnell -Original Message- From: Andrew Tracey [mailto:[EMAIL PROTECTED] Sent: 10 October 2005 15:01 To: Terry McDonnell Subject: MI-L SQL Querying Dear All Does anyone know

RE: MI-L SQL Querying

2004-11-30 Thread Tim Smith
This is the query you need Mid$(Column_name,10, 1) = 2 Or Mid$(Column_name,10, 1) = 3 Syntax: Mid$( str, num1, num2 ) Returns a portion of the string str starting at character position num1 and extending for num2 characters. Hope it works Cheers Tim -Original Message- From:

RE: MI-L SQL Querying

2004-11-30 Thread OSullivan. Jerry (IT Solutions)
Andrew, Try something like: 'Select * from Untitled where Mid$(ID,10,1) = 2 or Mid$(ID,10,1) = 3 into Selection' For Chars 'Select * from Untitled where Mid$(Str$(ID),10,1) = 2 or Mid$(Str$(ID),10,1) = 3 into Selection' For Decimals Enjoy, Jerry Jerry O'Sullivan GIS

RE: MI-L SQL Querying

2004-10-20 Thread Nielsen, Erik R
Andrew, Use the SQL query form then GROUP BY PropType, PropSit ORDER BY PropType, PRopSit This will give you A,D,123 A,E,456 .. B,D,101 Etc. Un less you really need the matrix form I reckon this is the best way to do it. Else I'll suggest Mapbasic. Cheers Erik -Original Message- From:

RE: MI-L SQL Querying

2002-07-09 Thread HANNA MICHAEL (TOR1MMH)
Hi Andrew, SELECT MyCol FROM MyTAB WHERE Len(MyCol) 40 Hope this helps, Michael Hanna Industrial Engineering United Parcel Service Canada Ltd. (905) 660-8688 -Original Message- From: Andrew Tracey [mailto:[EMAIL PROTECTED]] Sent: Tuesday, July 09, 2002 9:11 AM To: [EMAIL PROTECTED]

Re: MI-L SQL Querying

2002-07-09 Thread Dan_Page
I believe it's len(columnname) 40 Dan Andrew Tracey [EMAIL PROTECTED] on 07/09/2002 09:10:51 AM To:[EMAIL PROTECTED] cc: Subject:MI-L SQL Querying Dear All Can anybody help I am trying to pick out all records within a column that are more than 40 characters in length. Does