@@ -181,7 +181,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
181181 const schema = [
182182 { name : "location" , type : "SYMBOL" } ,
183183 { name : "temperature" , type : "DOUBLE" } ,
184- { name : "timestamp" , type : "TIMESTAMP " } ,
184+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
185185 ] ;
186186
187187 const sender = await Sender . fromConfig (
@@ -204,7 +204,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
204204 expect ( select1Result . count ) . toBe ( 1 ) ;
205205 expect ( select1Result . columns ) . toStrictEqual ( schema ) ;
206206 expect ( select1Result . dataset ) . toStrictEqual ( [
207- [ "us" , 17.1 , "2022-07-22T10:12:45.000000Z " ] ,
207+ [ "us" , 17.1 , "2022-07-22T10:12:45.000000000Z " ] ,
208208 ] ) ;
209209
210210 // ingest via client, add new column
@@ -232,14 +232,14 @@ describe("Sender tests with containerized QuestDB instance", () => {
232232 expect ( select2Result . columns ) . toStrictEqual ( [
233233 { name : "location" , type : "SYMBOL" } ,
234234 { name : "temperature" , type : "DOUBLE" } ,
235- { name : "timestamp" , type : "TIMESTAMP " } ,
235+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
236236 { name : "city" , type : "SYMBOL" } ,
237237 ] ) ;
238238 expect ( select2Result . dataset ) . toStrictEqual ( [
239- [ "us" , 17.1 , "2022-07-22T10:12:45.000000Z " , null ] ,
240- [ "us" , 17.36 , "2022-07-22T10:12:45.000666Z " , null ] ,
241- [ "emea" , 17.41 , "2022-07-22T10:12:45.000999Z " , null ] ,
242- [ "emea" , 18.81 , "2022-07-22T10:12:45.001234Z " , "london" ] ,
239+ [ "us" , 17.1 , "2022-07-22T10:12:45.000000000Z " , null ] ,
240+ [ "us" , 17.36 , "2022-07-22T10:12:45.000666000Z " , null ] ,
241+ [ "emea" , 17.41 , "2022-07-22T10:12:45.000999000Z " , null ] ,
242+ [ "emea" , 18.81 , "2022-07-22T10:12:45.001234000Z " , "london" ] ,
243243 ] ) ;
244244
245245 await sender . close ( ) ;
@@ -250,7 +250,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
250250 const schema = [
251251 { name : "location" , type : "SYMBOL" } ,
252252 { name : "temperatures" , type : "ARRAY" , elemType : "DOUBLE" , dim : 1 } ,
253- { name : "timestamp" , type : "TIMESTAMP " } ,
253+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
254254 ] ;
255255
256256 const sender = await Sender . fromConfig (
@@ -273,7 +273,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
273273 expect ( select1Result . count ) . toBe ( 1 ) ;
274274 expect ( select1Result . columns ) . toStrictEqual ( schema ) ;
275275 expect ( select1Result . dataset ) . toStrictEqual ( [
276- [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000Z " ] ,
276+ [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000000Z " ] ,
277277 ] ) ;
278278
279279 // ingest via client, add new columns
@@ -297,23 +297,23 @@ describe("Sender tests with containerized QuestDB instance", () => {
297297 expect ( select2Result . columns ) . toStrictEqual ( [
298298 { name : "location" , type : "SYMBOL" } ,
299299 { name : "temperatures" , type : "ARRAY" , elemType : "DOUBLE" , dim : 1 } ,
300- { name : "timestamp" , type : "TIMESTAMP " } ,
300+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
301301 { name : "city" , type : "SYMBOL" } ,
302302 { name : "daily_avg_temp" , type : "DOUBLE" } ,
303303 ] ) ;
304304 expect ( select2Result . dataset ) . toStrictEqual ( [
305- [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000Z " , null , null ] ,
305+ [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000000Z " , null , null ] ,
306306 [
307307 "us" ,
308308 [ 17.36 , 18.4 , 19.6 , 18.7 ] ,
309- "2022-07-22T10:12:45.000666Z " ,
309+ "2022-07-22T10:12:45.000666000Z " ,
310310 null ,
311311 null ,
312312 ] ,
313313 [
314314 "emea" ,
315315 [ 18.5 , 18.4 , 19.2 ] ,
316- "2022-07-22T10:12:45.001234Z " ,
316+ "2022-07-22T10:12:45.001234000Z " ,
317317 "london" ,
318318 18.7 ,
319319 ] ,
@@ -339,11 +339,11 @@ describe("Sender tests with containerized QuestDB instance", () => {
339339 . table ( tableName )
340340 . symbol ( "location" , "us" )
341341 . arrayColumn ( "temperatures" , [ 17.1 , 17.7 , 18.4 ] )
342- . at ( 1658484765000000000n , "ns" ) ;
342+ . at ( 1658484765000000n ) ;
343343 await sender
344344 . table ( tableName )
345345 . symbol ( "location" , "gb" )
346- . at ( 1658484765000666000n , "ns" ) ;
346+ . at ( 1658484765000666n ) ;
347347 await sender . flush ( ) ;
348348
349349 // wait for the table
@@ -382,15 +382,15 @@ describe("Sender tests with containerized QuestDB instance", () => {
382382 [ 17.1 , 17.7 , 18.4 ] ,
383383 [ 17.1 , 17.7 , 18.4 ] ,
384384 ] )
385- . at ( 1658484765000000000n , "ns " ) ;
385+ . at ( 1658484765000000n , "us " ) ;
386386 await sender
387387 . table ( tableName )
388388 . symbol ( "location" , "gb" )
389389 . arrayColumn ( "temperatures" , [
390390 [ 0.0 , 0.0 , 0.0 ] ,
391391 [ 0.0 , 0.0 , 0.0 ] ,
392392 ] )
393- . at ( 1658484765000666000n , "ns " ) ;
393+ . at ( 1658484765000666n , "us " ) ;
394394 await sender . flush ( ) ;
395395
396396 // wait for the table
@@ -428,7 +428,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
428428 const schema = [
429429 { name : "location" , type : "SYMBOL" } ,
430430 { name : "temperatures" , type : "ARRAY" , elemType : "DOUBLE" , dim : 1 } ,
431- { name : "timestamp" , type : "TIMESTAMP " } ,
431+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
432432 ] ;
433433
434434 const sender = await Sender . fromConfig (
@@ -457,8 +457,8 @@ describe("Sender tests with containerized QuestDB instance", () => {
457457 expect ( select1Result . count ) . toBe ( 2 ) ;
458458 expect ( select1Result . columns ) . toStrictEqual ( schema ) ;
459459 expect ( select1Result . dataset ) . toStrictEqual ( [
460- [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000Z " ] ,
461- [ "gb" , [ ] , "2022-07-22T10:12:45.000666Z " ] ,
460+ [ "us" , [ 17.1 , 17.7 , 18.4 ] , "2022-07-22T10:12:45.000000000Z " ] ,
461+ [ "gb" , [ ] , "2022-07-22T10:12:45.000666000Z " ] ,
462462 ] ) ;
463463
464464 await sender . close ( ) ;
@@ -469,7 +469,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
469469 const schema = [
470470 { name : "location" , type : "SYMBOL" } ,
471471 { name : "temperatures" , type : "ARRAY" , elemType : "DOUBLE" , dim : 2 } ,
472- { name : "timestamp" , type : "TIMESTAMP " } ,
472+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
473473 ] ;
474474
475475 const sender = await Sender . fromConfig (
@@ -507,11 +507,11 @@ describe("Sender tests with containerized QuestDB instance", () => {
507507 [ 17.1 , 17.7 ] ,
508508 [ 18.4 , 18.7 ] ,
509509 ] ,
510- "2022-07-22T10:12:45.000000Z " ,
510+ "2022-07-22T10:12:45.000000000Z " ,
511511 ] ,
512512 // todo: this should be [[], []]
513513 // probably a server bug
514- [ "gb" , [ ] , "2022-07-22T10:12:45.000666Z " ] ,
514+ [ "gb" , [ ] , "2022-07-22T10:12:45.000666000Z " ] ,
515515 ] ) ;
516516
517517 await sender . close ( ) ;
@@ -522,7 +522,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
522522 const schema = [
523523 { name : "location" , type : "SYMBOL" } ,
524524 { name : "temperature" , type : "DOUBLE" } ,
525- { name : "timestamp" , type : "TIMESTAMP " } ,
525+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
526526 ] ;
527527
528528 const sender = await Sender . fromConfig (
@@ -548,7 +548,7 @@ describe("Sender tests with containerized QuestDB instance", () => {
548548 expect ( select1Result . count ) . toBe ( 1 ) ;
549549 expect ( select1Result . columns ) . toStrictEqual ( schema ) ;
550550 expect ( select1Result . dataset ) . toStrictEqual ( [
551- [ "us" , 17.1 , "2022-07-22T10:12:45.000000Z " ] ,
551+ [ "us" , 17.1 , "2022-07-22T10:12:45.000000000Z " ] ,
552552 ] ) ;
553553
554554 // ingest via client, add new column
@@ -579,14 +579,14 @@ describe("Sender tests with containerized QuestDB instance", () => {
579579 expect ( select2Result . columns ) . toStrictEqual ( [
580580 { name : "location" , type : "SYMBOL" } ,
581581 { name : "temperature" , type : "DOUBLE" } ,
582- { name : "timestamp" , type : "TIMESTAMP " } ,
582+ { name : "timestamp" , type : "TIMESTAMP_NS " } ,
583583 { name : "city" , type : "SYMBOL" } ,
584584 ] ) ;
585585 expect ( select2Result . dataset ) . toStrictEqual ( [
586- [ "us" , 17.1 , "2022-07-22T10:12:45.000000Z " , null ] ,
587- [ "us" , 17.36 , "2022-07-22T10:12:45.000666Z " , null ] ,
588- [ "emea" , 17.41 , "2022-07-22T10:12:45.000999Z " , null ] ,
589- [ "emea" , 18.81 , "2022-07-22T10:12:45.001234Z " , "london" ] ,
586+ [ "us" , 17.1 , "2022-07-22T10:12:45.000000000Z " , null ] ,
587+ [ "us" , 17.36 , "2022-07-22T10:12:45.000666000Z " , null ] ,
588+ [ "emea" , 17.41 , "2022-07-22T10:12:45.000999000Z " , null ] ,
589+ [ "emea" , 18.81 , "2022-07-22T10:12:45.001234000Z " , "london" ] ,
590590 ] ) ;
591591
592592 await sender . close ( ) ;
0 commit comments