PageRenderTime 806ms CodeModel.GetById 159ms app.highlight 1ms RepoModel.GetById 104ms app.codeStats 36ms

/Rhino.Etl.Tests/Dsl/UsersToPeopleBulk.boo

http://github.com/ayende/rhino-etl
Boo | 16 lines | 15 code | 1 blank | 0 comment | 2 complexity | 65c7e8456af471d4c17de62ef9e4c28e MD5 | raw file
 1operation split_name_bulk:
 2    for row in rows:
 3        continue if row.Name is null
 4        row.FirstName = row.Name.Split()[0]
 5        row.LastName = row.Name.Split()[1]
 6        yield row
 7    
 8process UsersToPeopleBulk:
 9    input "test", Command = "SELECT id, name, email  FROM Users"
10    split_name_bulk()
11    sqlBulkInsert "test", "People", TableLock = true :
12        map "id", int
13        map "firstname"
14        map "lastname"
15        map "email"
16        map "userid", "id", int