Giter Club home page Giter Club logo

simple-mongodb's People

Contributors

danielwertheim avatar skipme avatar

Watchers

 avatar

Forkers

lrcchuan2016

simple-mongodb's Issues

Date values are not serialized correctly in queries (just calling ToString() is not sufficient in this case)

What steps will reproduce the problem?
1. Pass a DateTime object to the any of the Between(), Lt(), Gt() methods
of a QueryProperty object and try to execute the query.

What is the expected output? What do you see instead?

Correctly the generated JSON should look like:
{ Date: { $gte: "\/Date(1230764400000+0100)\/", $lte:
"\/Date(1274047200000+0200)\/" } }

Instead it internally just calls ToString() on the DateTime objects what
results in something like:
{ Date: { $gte: 01.01.2009 00:00:00, $lte: 17.05.2010 00:00:00 } }

To fix the problem I used JsonConvert.SerializeObject() and passed strings.
You might consider using JsonConvert internally instead of ToString() or
provide overloads for DateTime.

Original issue reported on code.google.com by [email protected] on 17 May 2010 at 3:19

ToKeyValue_DateTime_Equals unit test fails

What steps will reproduce the problem?
1. Get latest
2. Build and Run All Unit Tests

What is the expected output? What do you see instead?
ToKeyValue_DateTime_Equals unit to succeed. Assert.AreEqual failed. 
Expected:<1/1/2010 1:47:53 PM>. Actual:<1/1/2010 4:47:53 AM>

What version of the product are you using? On what operating system?
0.17. Mongodb v1.4.2, Windows 7 64 bit.

Please provide any additional information below.
Seems like the test isn't taking timezone into consideration.

Original issue reported on code.google.com by [email protected] on 4 May 2010 at 1:49

Improvement in quering

I have such a class 
 [JsonObject(Title = "Mrk")]
    public class Mark
    {
        [JsonProperty(PropertyName = "t")]
        public long tid;
        [JsonProperty(PropertyName = "m")]
        public float mark = 0.1f;
    }
I want to query collection with full field name mark instead of "m", there 
will be no need to dead with dynamic code so that should be faster, or it 
could be done via JSON selector object  

Original issue reported on code.google.com by [email protected] on 20 Mar 2010 at 6:19

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.