@@ -338,77 +338,87 @@ corresponds to your Atlas cluster.
338338Run a Sample Query
339339------------------
340340
341- .. step:: Create a Project Directory
341+ You can create an application that connects to your MongoDB
342+ deployment and retrieves data from the ``movies`` collection
343+ in the ``sample_mflix`` database.
342344
343- In your shell, navigate to where you want to create your
344- application, then run the following command to create a
345- directory called ``c-quickstart`` for this project:
345+ To learn more about the ``sample_mflix`` database, see :atlas:`Sample Mflix Dataset
346+ </sample-data/sample-mflix/>` in the Atlas documentation.
346347
347- .. code-block:: bash
348+ .. procedure::
349+ :style: connected
348350
349- mkdir c-quickstart
351+ .. step:: Create a Project Directory
350352
351- Select the tab corresponding to your operating system and run the
352- following commands to create a ``quickstart.c`` application file
353- in the ``c-quickstart`` directory:
353+ In your shell, navigate to where you want to create your
354+ application, then run the following command to create a
355+ directory called ``c-quickstart`` for this project:
356+
357+ .. code-block:: bash
354358
355- .. tabs::
359+ mkdir c-quickstart
356360
357- .. tab:: macOS / Linux
358- :tabid: create-file-mac-linux
361+ Select the tab corresponding to your operating system and run the
362+ following commands to create a ``quickstart.c`` application file
363+ in the ``c-quickstart`` directory:
359364
360- .. code-block:: bash
365+ .. tabs::
361366
362- cd c-quickstart
363- touch quickstart.c
367+ .. tab:: macOS / Linux
368+ :tabid: create-file-mac-linux
364369
365- .. tab:: Windows
366- :tabid: create-file-windows
370+ .. code-block:: bash
367371
368- .. code-block:: bash
372+ cd c-quickstart
373+ touch quickstart.c
369374
370- cd c-quickstart
371- type nul > quickstart.c
375+ .. tab:: Windows
376+ :tabid: create-file-windows
372377
373- .. step:: Create Your C Driver Application
378+ .. code-block:: bash
374379
375- Copy and paste the following code into the ``quickstart.c`` file, which queries
376- the ``movies`` collection in the ``sample_mflix`` database:
380+ cd c-quickstart
381+ type nul > quickstart.c
377382
378- .. literalinclude:: /includes/get-started/quickstart.c
379- :language: c
383+ .. step:: Create Your C Driver Application
380384
381- .. step:: Assign the Connection String
385+ Copy and paste the following code into the ``quickstart.c`` file, which queries
386+ the ``movies`` collection in the ``sample_mflix`` database:
382387
383- Replace the ``<connection string>`` placeholder with the
384- connection string that you copied from the :ref:`c-get-started-connection-string`
385- step of this guide.
388+ .. literalinclude:: /includes/get-started/quickstart.c
389+ :language: c
386390
387- .. step:: Run Your C Application
391+ .. step:: Assign the Connection String
388392
389- In your shell, run the following commands to compile and run this application:
390-
391- .. code-block:: none
393+ Replace the ``<connection string>`` placeholder with the
394+ connection string that you copied from the :ref:`c-get-started-connection-string`
395+ step of this guide.
396+
397+ .. step:: Run Your C Application
398+
399+ In your shell, run the following commands to compile and run this application:
400+
401+ .. code-block:: none
392402
393- gcc -o quickstartc quickstart.c $(pkg-config --libs --cflags libmongoc-1.0)
394- ./quickstartc
403+ gcc -o quickstartc quickstart.c $(pkg-config --libs --cflags libmongoc-1.0)
404+ ./quickstartc
395405
396- The command line output contains details about the retrieved movie
397- document:
406+ The command line output contains details about the retrieved movie
407+ document:
398408
399- .. code-block:: none
400- :copyable: false
409+ .. code-block:: none
410+ :copyable: false
401411
402- { "_id" : { "$oid" : "..." },
403- "plot" : "Two imprisoned men bond over a number of years, finding solace
404- and eventual redemption through acts of common decency.",
405- ...
406- "title" : "The Shawshank Redemption",
407- ...
412+ { "_id" : { "$oid" : "..." },
413+ "plot" : "Two imprisoned men bond over a number of years, finding solace
414+ and eventual redemption through acts of common decency.",
415+ ...
416+ "title" : "The Shawshank Redemption",
417+ ...
408418
409- If you encounter an error or see no output, ensure that you specified the
410- proper connection string in the ``quickstart.c`` file and that you loaded the
411- sample data.
419+ If you encounter an error or see no output, ensure that you specified the
420+ proper connection string in the ``quickstart.c`` file and that you loaded the
421+ sample data.
412422
413423After you complete these steps, you have a working application that
414424uses the driver to connect to your MongoDB deployment, runs a query on
0 commit comments