更多“以下语句执行后myTable的名称是()。 Dim myTable as DataTable myTable=New System.Data.DataTable()A、Table1B、Table2C、TableND、Nothing”相关问题
  • 第1题:

    下列声明并创建Connection对象的语句,正确的是()。

    A、Dim ADOcn As Connection

    B、Dim ADOcn As New Connection

    C、Declare ADOcn As New Connection

    D、Declare ADOcn As Connection


    参考答案:B

  • 第2题:

    下列过程的功能是:将当前数据库文件中“学生表”的所有学生“年龄”加1。 Private Sub SetAgeplus2_Click( ) Dim cn As New ADODB.Connection Dim rs As New ADODB.Recordset Dim fd As ADODB.Field Dim strConnect As String Dim strSQL As String Set cn=CurrentProject.Connection strSQL=“Select年龄from学生表” rs.Open strSQl,cn,adOpenDynamic,adlockOptimistic,adCmdText set fd=rs.Fields(“年龄”) Do While Not rs.EOF fd=__________ rs.Update rs.__________ Loop rs.Close cn.Close Set rs= Nothing Set cn=Nothing End Sub 横线处应填写的内容是( )。

    A.fd-1 0pen

    B.fd+1 close

    C.fd+1 MoveNext

    D.fd-1 Recordset


    正确答案:C
    题目要求是将年龄加l,因此fd=fd+1,作为一个DoWhile循环,要将循环推下去,因此要填写关键词MoveNext。

  • 第3题:

    执行语句Dim X,Y As Integer后( )


    正确答案:D
    当在一个Dim语句中定义多个变量时,每个变量都要用As子句表明其类型,否则该变量被看做是变体类型。所以,在DimX,YAsInteger中,X被定义为变体类型,Y被定义为整型。

  • 第4题:

    以下语句执行时,从键盘上输入Zhang,执行结果是______。 Dim a As String a=InputBox("Input","","Name") Print a

    A.Input

    B.Name

    C.Zhang

    D.空字符串


    正确答案:C

  • 第5题:

    Consider the Mysql Enterprise Audit plugin. A CSV file called data.csv has 100 rows of data. The stored procedure prepare_db ( ) has 10 auditable statements. You run the following statements in the mydb database: Mysql> CALL prepare_db ( ); Mysql> LOAD DATA INFILE '/tmp/data.cav' INTO TABLE mytable; Mysql> SHOW TABLES; How many events are added to the audit log as a result of the preceding statements?()

    • A、12; only top-level statements and stored procedure events are logged
    • B、111; top-level statements and all lower-level statements are logged
    • C、3; only the top-level statements are logged
    • D、102; top-level statements are logged, but LOAD DATA INFILE is logged as a separate event

    正确答案:C

  • 第6题:

    以下语句执行后,myDataSet中增加的表的名称是()。 dim myDataSet as new DataSet() myDataSet.Tables.Add()

    • A、Table1
    • B、Table2
    • C、TableN
    • D、Nothing

    正确答案:A

  • 第7题:

    以下语句获取表中第1行第1列(FirstName列)的数据,其中错误的语句是()。

    • A、myTable.Rows(0).Item("FirstName")
    • B、myTable.Rows(0)("FirstName")
    • C、myTable.Rows(0)(1)
    • D、myTable.Rows(0)(0)
    • E、myTable.Rows(0).Item(0)

    正确答案:C

  • 第8题:

    在SQL Server中,下列标识符可以作为本地临时表名的是()。

    • A、##MyTable
    • B、@@MyTable
    • C、@MyTable
    • D、#MyTable

    正确答案:D

  • 第9题:

    You are creating a DataTable. You use the following code segment to create the DataTable. (Line numbers are included for reference only.) 01 Dim dt As New DataTable("Products") 02 dt.Columns.Add(New DataColumn("Price", _ GetType(Decimal))) 03 dt.Columns.Add(New DataColumn("Quantity", _ GetType(Int32))) 04 Dim dc As DataColumn = New DataColumn("Total", _ GetType(Decimal)) 05 dt.Columns.Add(dc) You need to ensure that the Total column is set to the value of the Price column multiplied by the Quantity column when new rows are added or changed. What should you do? ()

    • A、Add the following code segment after line 05. dc.ExtendedProperties("Total") = "Price * Quantity"
    • B、Add the following code segment after line 05. dc.Expression = "Price * Quantity"
    • C、Write an event handler for the DataTable's TableNewRow event that updates the row's Total.
    • D、Write an event handler for the DataTable's ColumnChanged event that updates the row's Total.

    正确答案:B

  • 第10题:

    单选题
    下列命令不能执行的是()。
    A

    SELECT * FROM [select]

    B

    SELECT * FROM @MyTable

    C

    SELECT * FROM [MyTable]

    D

    SELECT * FROM MyTable


    正确答案: D
    解析: 暂无解析

  • 第11题:

    单选题
    在SQL Server中,下列标识符可以作为本地临时表名的是()。
    A

    ##MyTable

    B

    @@MyTable

    C

    @MyTable

    D

    #MyTable


    正确答案: B
    解析: 暂无解析

  • 第12题:

    单选题
    以下语句执行后myTable的名称是()。 Dim myTable as DataTable myTable=New System.Data.DataTable()
    A

    Table1

    B

    Table2

    C

    TableN

    D

    Nothing


    正确答案: D
    解析: 暂无解析

  • 第13题:

    已知ds1、ds2分别代表两个不同的DataSet对象。其中ds1已包含名为“Customer”的DataTable对象,且该DataTable对象被变量dt_Customer引用。已知dt_Customer表有300条记录,则执行下列语句后,新的数据表new_dt_Customer中包含D_条记录。 DataTablenew_dt_Customer=dt_Customer.Copy();

    A.0

    B.100

    C.200

    D.300


    正确答案:D

  • 第14题:

    将查询学生的结果放在数组MyArray中的SQL语句是: SELECT*FROM学生表WHERE籍贯=’北京’_________ 上面空缺的短语是( )。

    A. INTO CURSOR MyCumor

    B. TO ARRAY MyArray

    C. INTO ARRAY MyArray

    D. INTO TABLE MyTable


    正确答案:C
    INTO CURSOR、INTO TABLE、INTO AR- RAY都是SELECT语句的短语,将查询结果放在数组中应使用INTO ARRAY短语。INTO CURSOR是将查询结果存入在临时文件中。INTO TABLE是将查询结果存放在永久表中。TO ARRAY不是正确的SQL语句。

  • 第15题:

    执行以下语句后显示结果为______。 Dim x As Integer If x Then Print x Else Printx-1

    A.1

    B.0

    C.-1

    D.不确定


    正确答案:C
    解析:Dim定义的变量,If语句在VisualBasic中,Dim用于在标准模块、窗体模块或过程中定义变量或数组。而当引用Dim定义的变量时,变量值会被重新设置(数值变量重新设置为0,字符串变量被设置为空)。If语句的格式:If条件Then若干条语句Else若于条语句或者If条件Then若干条语句Else若干条语句EndIfIf语句的执行方式:当“条件”为真的时候,执行Then后面的语句;“条件”为假,执行Else后面的语句。如果“条件”是数值表达式,则数值表达式为非。值时,“条件”为真;数值表达式为。时,“条件”为假。在此题中,“条件”是整型变量x,其值为0,“条件”为假,执行Else分支,即打印出-1。

  • 第16题:

    执行以下语句后显示结果为______。 Dim x As Integer If X Then Print x Else Print X-1

    A.1

    B.0

    C.-1

    D.不确定


    正确答案:C
    解析:Dim定义的变量,If语句
    在Visual Basic中,Dim用于在标准模块、窗体模块或过程中定义变量或数组。而当引用Dim定义的变量时,变量值会被重新设置(数值变量重新设置为0,字符串变量被设置为空)。
    If语句的格式:
    If条件Then若干条语句Else若干条语句 或者
    If条件Then
    若干条语句
    Else
    若干条语句
    End If
    If语句的执行方式:
    当“条件”为真的时候,执行Then后面的语句;“条件”为假,执行Else后面的语句。
    如果“条件”是数值表达式,则数值表达式为非0值时,“条件”为真;数值表达式为0时,“条件”为假。
    在此题中,“条件”是整型变量x,其值为0,“条件”为假,执行Else分支,即打印出-1。

  • 第17题:

    要删除mytable表中的myindex索引,可以使用()语句。

    • A、DROP myindex
    • B、DROP mytable.myindex
    • C、DROP INDEX myindex
    • D、DROP INDEX mytable.myindex

    正确答案:D

  • 第18题:

    myTable=New System.Data.DataTable(),myTable的名称是Table1。


    正确答案:正确

  • 第19题:

    下列命令不能执行的是()。

    • A、SELECT * FROM [select]
    • B、SELECT * FROM @MyTable
    • C、SELECT * FROM [MyTable]
    • D、SELECT * FROM MyTable

    正确答案:B

  • 第20题:

    You issued the following command:        SQL> DROP TABLE MYTABLE;        SQL> SHOW RECYCLEBIN  The following output is returned:        ORIGINAL NAME RECYCLEBIN NAME               OBJECT TYPE      DROP TIME        ------------- ------------------------------ --------------- --------------------        MYTABLE BIN$04LhcpndanfgMAAAAAANPw==$0     TABLE           2005-01-13:20:11:31  You want to drop the table, MYTABLE, from the Recycle Bin. Which two commands can you issue to accomplish the desired task?()

    • A、 DROP TABLE MYTABLE PURGE;
    • B、 PURGE RECYCLEBIN;
    • C、 PURGE TABLE MYTABLE;
    • D、 PURGE TABLE BIN$04LhcpndanfgMAAAAAANPw==$0;

    正确答案:C,D

  • 第21题:

    判断题
    myTable=New System.Data.DataTable(),myTable的名称是Table1。
    A

    B


    正确答案:
    解析: 暂无解析

  • 第22题:

    单选题
    You are creating a DataTable. You use the following code segment to create the DataTable. (Line numbers are included for reference only.) 01 Dim dt As New DataTable("Products") 02 dt.Columns.Add(New DataColumn("Price", _ GetType(Decimal))) 03 dt.Columns.Add(New DataColumn("Quantity", _ GetType(Int32))) 04 Dim dc As DataColumn = New DataColumn("Total", _ GetType(Decimal)) 05 dt.Columns.Add(dc) You need to ensure that the Total column is set to the value of the Price column multiplied by the Quantity column when new rows are added or changed. What should you do? ()
    A

    Add the following code segment after line 05. dc.ExtendedProperties(Total) = Price * Quantity

    B

    Add the following code segment after line 05. dc.Expression = Price * Quantity

    C

    Write an event handler for the DataTable's TableNewRow event that updates the row's Total.

    D

    Write an event handler for the DataTable's ColumnChanged event that updates the row's Total.


    正确答案: D
    解析: 暂无解析

  • 第23题:

    单选题
    以下语句执行后,myDataSet中增加的表的名称是()。 dim myDataSet as new DataSet() myDataSet.Tables.Add()
    A

    Table1

    B

    Table2

    C

    TableN

    D

    Nothing


    正确答案: A
    解析: 暂无解析