Hello Soren
I hope that you have MapBasic!
Do something like this:
Declare Sub main
Sub Main
Dim i as integer
Dim SelectCommandToRun as string
Dim CommitCommandToRun as String
Dim CloseTableCommand as String
Select YourColumn8name from YourTable Group by YourColumn8name into
PossibleDigits
Commit Table PossibleDigits as "C:\temp\PossibleDigits"
Close PossibleDigits
Open table "C:\temp\PossibleDigits"
Fetch first from PossibleDigits
Do while not EOT(PossibleDigits)
SelectCommandToRun="Select * From YourTable Where
YourColumn8name="+Str$(PossibleDigits.COL8)+"Into
"+Str$(PossibleDigits.COL8)
Run command SelectCommandToRun
CommitCommandToRun="Commit table "+Str$(PossibleDigits.COL8)+" as
"""C:\Temp\"+Str$(PossibleDigits.COL8)+"+Tab""
Run Command CommitCommandToRun
CloseTableCommand="Close table "+Str$(PossibleDigits.COL8)
Fetch Next From PossibleDigits
Loop
End sub
Well I'm not certain that i got the exact right number of ""�s in the
commands above but adjust that and it can fix your task.
Regards
Thomas Brix Lyng
Frederikshavn Municipal Administration
Denmark
-----Oprindelig meddelelse-----
Fra: S�ren [mailto:soren.lindqvist@;telia.com]
Sendt: 15. november 2002 10:41
Til: [EMAIL PROTECTED]
Emne: MI-L Help needed
Dear readers,
I need some help on this if its even possible to do it.
I have one table with 10 columns with 9000 rows.
On column 8 I have a 5 digit number (Integer) and around 7-800 different
combinations. What I have to do is run a query on each and save to a new
table with the name of the 5 digit number.
Is there anyway to do this automatically or do I have to run query on
each 7-800 of them that will take many hours to do?
Thanks in advance
Regards
Soren
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 4100
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 4102