这个问题我问了好多遍了,但回答的都很含糊,我现在还是没有搞懂,我想是不是分数给的太少了,现在我给100分
ConDatabase.Execute "CREATE TABLE [Account] (" & _
                    "[yfm] text (20)," & _
                    "[mima] text (15) " & _
                    ")"
这张只有两个字段的表在建表时如何定义yfm为关键字?

解决方案 »

  1.   

    "[yfm] text(20) primary key ,"
      

  2.   

    ConDatabase.Execute "CREATE TABLE [Account] (" & _
                        "[yfm] text (20) primary key," & _
                        "[mima] text (15) " & _
                        ")"
    这样建表也不行
      

  3.   

    这样ConDatabase.Execute "CREATE TABLE [Account] (" & _
                        "[yfm] text (20) ," & _
                        "[mima] text (15), " & _
                        "Constraint Primary Key ([yfm])" & _
                        ")"
      

  4.   

    漏了名字ConDatabase.Execute "CREATE TABLE [Account] (" & _
                        "[yfm] text (20) ," & _
                        "[mima] text (15), " & _
                        "Constraint pk_Account Primary Key ([yfm])" & _
                        ")"