4.19.1 Sending a SQL Batch

In this example, a SQL statement is sent to the server and the results are sent to the client. The SQL statement is as follows:

 SQLStatement =  select name, empid from employees
                 update employees set salary = salary * 1.1
                 select name from employees where department = 'HR'
  
 Client:    SQLStatement
  
 Server:    COLMETADATA   data stream
            ROW           data stream
            .
            .
            ROW           data stream
            DONE          data stream (with DONE_COUNT & DONE_MORE
                                       bits set)
            DONE          data stream (for UPDATE, with DONE_COUNT & 
                                       DONE_MORE bits set)
            COLMETADATA   data stream
            ROW           data stream
            .
            .
            ROW           data stream
            DONE          data stream (with DONE_COUNT bit set)
Show: