Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
ADODB fox table SQL - Alter Table
Message
From
15/02/2000 10:54:35
 
 
To
All
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
ADODB fox table SQL - Alter Table
Miscellaneous
Thread ID:
00332218
Message ID:
00332218
Views:
57
I have a table in the field that currently has a c(30) field and now I want a c(4). I have executed the following code without error and without altering the table :) What is the problem with this code?
    If Dir("C:\test.dbf", vbNormal) <> "" Then
        Dim cn1 As New ADODB.Connection
        Dim cm1 As New ADODB.Command
        cn1.Open "Driver=Microsoft Visual Foxpro Driver;UID=;SourceType=DBF;Deleted=YES;Null=NO;SourceDB=D:\"
        cm1.ActiveConnection = cn1
        cm1.CommandType = adCmdUnknown
        cm1.CommandText = "ALTER TABLE C:\test.dbf ALTER COLUMN Field3 c(4)"
       cm1.Execute
    End If
Also, any tips for the SQL replace commands before I get into that?
~Joe Johnston USA

"If ye love wealth better than liberty, the tranquility of servitude better than the animated contest of freedom, go home from us in peace. We ask not your counsel or arms. Crouch down and lick the hands which feed you. May your chains set lightly upon you, and may posterity forget that ye were our countrymen."
~Samuel Adams

Next
Reply
Map
View

Click here to load this message in the networking platform