mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
mongoose
• 如果是 ,使用 方法,如果是 ,使用
方法
mongoose
mongoose
http://mongoosejs.com/docs/connections.html
https://cnodejs.org/topic/504b4924e2b84515770103dd

More Related Content

PPT
Ken 20150306 心得分享
PPTX
Powershell enum
PPTX
Learning tech week_1_james
PPT
Tipo music-ui-規劃原則
PDF
2013 jsdc webworker
PPT
Raphael JavaScript Library
PPTX
Introduction of lambda expression and predicate builder
PPTX
Ken 20150306 心得分享
Powershell enum
Learning tech week_1_james
Tipo music-ui-規劃原則
2013 jsdc webworker
Raphael JavaScript Library
Introduction of lambda expression and predicate builder

More from LearningTech (20)

PPTX
PostCss
PPTX
ReactJs
PPTX
Docker
PPTX
Semantic ui
PPTX
node.js errors
PPTX
Process control nodejs
PPTX
Expression tree
PPTX
SQL 效能調校
PPTX
flexbox report
PPTX
Vic weekly learning_20160504
PPTX
Reflection & activator
PPTX
Peggy markdown
PPTX
Node child process
PPTX
20160415ken.lee
PPTX
Peggy elasticsearch應用
PPTX
Expression tree
PPTX
Vic weekly learning_20160325
PPTX
D3js learning tips
PPTX
git command
PDF
Asp.net MVC DI
PostCss
ReactJs
Docker
Semantic ui
node.js errors
Process control nodejs
Expression tree
SQL 效能調校
flexbox report
Vic weekly learning_20160504
Reflection & activator
Peggy markdown
Node child process
20160415ken.lee
Peggy elasticsearch應用
Expression tree
Vic weekly learning_20160325
D3js learning tips
git command
Asp.net MVC DI
Ad

Editor's Notes

  • #4: Schema生成Model, Model創造Entity, Model和Entity都可對資料庫操作造成影響,但Model比Entity更具操作性。
  • #5: //定義一個屬性name,類型為String
  • #11: //查詢類似數據
  • #14: 只有在執行exec方法時才執行查詢,而且必須有回調。
  • #17: update第一個參數是查詢條件,第二個參數是更新的對象,但不能更新主鍵,這就是為什麼要刪除主鍵的原因。 PersonModel.update({_id:_id},{$set:{name:'MDragon'}},function(err){});
  • #19: 如果是Entity,使用save方法,如果是Model,使用create方法 兩種新增方法區別在於,如果使用Model新增時,傳入的對象只能是純淨的JSON對象,不能是由Model創建的實體,原因是:由Model創建的實體krouky雖然打印是只有{name:'krouky'},但是krouky屬於Entity,包含有Schema屬性和Model數據庫行為模型。