1
1
using SQLite
2
- using Base. Test, Nulls , WeakRefStrings, DataStreams, DataFrames
2
+ using Base. Test, Missings , WeakRefStrings, DataStreams, DataFrames
3
3
4
4
import Base: + , ==
5
5
@@ -24,7 +24,7 @@ results1 = SQLite.tables(db)
24
24
results = SQLite. query (db," SELECT * FROM Employee;" )
25
25
@test length (results) == 15
26
26
@test size (Data. schema (results)) == (8 ,15 )
27
- @test isnull (results[5 ][1 ])
27
+ @test ismissing (results[5 ][1 ])
28
28
29
29
SQLite. query (db," SELECT * FROM Album;" )
30
30
SQLite. query (db," SELECT a.*, b.AlbumId
@@ -92,7 +92,7 @@ r = SQLite.query(db, "select * from $(sink.tablename)")
92
92
@test all ([typeof (i) for i in r[1 ]] .== Float64)
93
93
SQLite. drop! (db, " $(sink. tablename) " )
94
94
95
- rng = Date (2013 ): Date (2013 ,1 ,5 )
95
+ rng = Date (2013 ): Dates . Day ( 1 ) : Date (2013 ,1 ,5 )
96
96
dt = DataFrame (i= collect (rng), j= collect (rng))
97
97
sink = SQLite. Sink (db, " temp" , Data. schema (dt))
98
98
SQLite. load (sink, dt)
@@ -244,9 +244,9 @@ SQLite.bind!(stmt, "@a", 1)
244
244
245
245
binddb = SQLite. DB ()
246
246
SQLite. query (binddb, " CREATE TABLE temp (n NULL, i6 INT, f REAL, s TEXT, a BLOB)" )
247
- SQLite. query (binddb, " INSERT INTO temp VALUES (?1, ?2, ?3, ?4, ?5)" ; values= Any[null , convert (Int64,6 ), 6.4 , " some text" , b " bytearray" ])
247
+ SQLite. query (binddb, " INSERT INTO temp VALUES (?1, ?2, ?3, ?4, ?5)" ; values= Any[missing , convert (Int64,6 ), 6.4 , " some text" , b " bytearray" ])
248
248
r = SQLite. query (binddb, " SELECT * FROM temp" )
249
- @test isa (r[1 ][1 ], Null )
249
+ @test isa (r[1 ][1 ], Missing )
250
250
@test isa (r[2 ][1 ], Int)
251
251
@test isa (r[3 ][1 ], Float64)
252
252
@test isa (r[4 ][1 ], AbstractString)
0 commit comments