Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F7404404
dump-mongo.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
470 B
Referenced Files
None
Subscribers
None
dump-mongo.js
View Options
#!/usr/bin/env node
'use strict'
;
const
mongodb
=
require
(
'mongodb'
);
new
mongodb
.
MongoClient
(
new
mongodb
.
Server
(
'localhost'
,
27017
),
// eslint-disable-next-line camelcase
{
native_parser
:
true
}
).
connect
().
then
(
(
client
)
=>
{
const
db
=
client
.
db
(
'test'
);
return
db
.
collection
(
'vedocstore'
).
find
().
toArray
().
then
(
(
result
)
=>
{
console
.
log
(
JSON
.
stringify
(
result
)
);
client
.
close
();
}
);
}
).
catch
(
(
err
)
=>
{
console
.
error
(
err
);
}
);
File Metadata
Details
Attached
Mime Type
application/javascript
Expires
Sat, Nov 21, 19:09 (1 d, 1 h)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
72/37/e276ebfa7d0f78671a9f24c12aef
Default Alt Text
dump-mongo.js (470 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment