問題タブ [linq-to-mysql]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票する
1 に答える
244 参照

c# - LINQを使用してサブクエリで上位1つの結果を取得するためにorderbyが機能しない

サブクエリを使用して、子テーブルから上位 1 つの結果を取得しようとしています。サブクエリを使用して使用しようとするorderby or OrderByDescendingと、スローされます

NullReferenceException

. orderby or OrderByDescending私のクエリを使用せずに正常に実行します。しかし、サブクエリの最後のレコードを取得したいです。私のアプリはMysqlデータベースに接続されています。

私のコードは以下のとおりです