Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #102960

Re: Unable to insert data into MongoDB.

Path csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail
From Peter Otten <__peter__@web.de>
Newsgroups comp.lang.python
Subject Re: Unable to insert data into MongoDB.
Date Mon, 15 Feb 2016 12:36:17 +0100
Organization None
Lines 18
Message-ID <mailman.139.1455536203.22075.python-list@python.org> (permalink)
References <eebb44e3-fcd3-4503-ad2b-5cfcc75ef6fa@googlegroups.com> <mailman.50.1455206980.22075.python-list@python.org> <8bb40e3f-57ce-4d5a-a426-6b56cebc8de7@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding 7Bit
X-Trace news.uni-berlin.de rLUdNuGA3DFgP+fR1yyPyAKFN2gpLaTbJT4YXL8fb8ng==
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.002
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'debug': 0.04; 'scripts': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'scripts,': 0.09; 'subject:into': 0.09; 'made-up': 0.16; 'received:80.91.229.3': 0.16; 'received:dip0.t-ipconnect.de': 0.16; 'received:io': 0.16; 'received:plane.gmane.org': 0.16; 'received:psf.io': 0.16; 'received:t-ipconnect.de': 0.16; 'wrote:': 0.16; 'changes': 0.20; 'script': 0.25; 'header:User- Agent:1': 0.26; 'header:X-Complaints-To:1': 0.26; 'actual': 0.28; 'another.': 0.29; 'print': 0.30; 'code': 0.30; 'changed': 0.33; 'machine.': 0.33; 'server': 0.34; 'replace': 0.35; 'instead': 0.36; 'data.': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'two': 0.37; 'received:org': 0.37; '(2)': 0.37; '(1)': 0.38; 'data': 0.39; 'to:addr:python.org': 0.40; 'received:de': 0.40; 'your': 0.60; 'hope': 0.61; 'sample': 0.63; 'satisfaction': 0.72
X-Injected-Via-Gmane http://gmane.org/
X-Gmane-NNTP-Posting-Host p57bd81b4.dip0.t-ipconnect.de
User-Agent KNode/4.13.3
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.21rc2
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Xref csiph.com comp.lang.python:102960

Show key headers only | View raw


Arjun Srivatsa wrote:

> I changed the port number from 27017 to 55555 in the code segment:

Instead of throwing arbitrary changes at your script in the hope that one 
works I recommend that you write two independent scripts, from scratch:

(1) write_to_db.py: 
Write made-up data into the MongoDB on your local machine.

(2) read_from_server.py: 
Read data from the server and print it to stdout.

Reduce these scripts to the bare minimum. Debug them one ofter another.

Once both scripts work to your satisfaction replace the sample data in 
script one with code from script two that reads actual data.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-11 07:12 -0800
  Re: Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-11 08:07 -0800
  Re: Unable to insert data into MongoDB. MRAB <python@mrabarnett.plus.com> - 2016-02-11 16:09 +0000
    Re: Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-15 02:44 -0800
      Re: Unable to insert data into MongoDB. Peter Otten <__peter__@web.de> - 2016-02-15 12:36 +0100
        Re: Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-15 07:00 -0800
          Re: Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-15 07:28 -0800
          Re: Unable to insert data into MongoDB. Peter Otten <__peter__@web.de> - 2016-02-15 17:33 +0100
            Re: Unable to insert data into MongoDB. Arjun Srivatsa <arjuns123@gmail.com> - 2016-02-16 04:41 -0800
  Re: Unable to insert data into MongoDB. Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-02-11 20:06 -0500

csiph-web