Skip to content

Commit e647538

Browse files
committed
list fixes
1 parent 5c1c6ee commit e647538

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

source/interact-data/modify-results.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,28 +173,35 @@ each field.
173173
You can specify the sort direction in the following ways:
174174

175175
- Integers ``1`` (ascending) and ``-1`` (descending)
176+
176177
- Example: ``Band.order(name: 1, year: -1)``
177178

178179
- Symbols ``:asc`` and ``:desc``
180+
179181
- Example: ``Band.order(name: :asc)``
180182

181183
- Strings ``"asc"`` and ``"desc"``
184+
182185
- Example: ``Band.order_by(name: "asc", year: "desc")``
183186

184187
The ``order()`` method also accepts the following sort specifications:
185188

186189
- Array of two-element arrays:
187190

188191
- Strings
192+
189193
- Example: ``Band.order([['name', 'asc'], ['year', 'desc']])``
190194

191195
- Symbols
196+
192197
- Example: ``Band.order([[:name, :asc]])``
193198

194199
- ``asc`` and ``desc`` methods on symbols
200+
195201
- Example: ``Band.order(:name.asc, :year.desc)``
196202

197203
- SQL syntax
204+
198205
- Example: ``Band.order('name desc')``
199206

200207
You can also use the ``asc()`` and ``desc()`` methods instead of using

0 commit comments

Comments
 (0)