找回密码
 FreeOZ用户注册
查看: 4314|回复: 2
打印 上一主题 下一主题

[论坛技术] 生成LINQ语句的好工具LINQPAD

[复制链接]
跳转到指定楼层
1#
发表于 16-6-2008 12:31:01 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
提示: 作者被禁止或删除, 无法发言

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有帐号?FreeOZ用户注册

x
http://www.linqpad.net/

这个工具的确帮助我学习了LINQ,而且用它来调试linq也很方便。学习LINQ的好工具,可惜原来的版本不支持想VS里面字段名和类名的映射,这样这里写好的LINQ语句,还要手工调整每个字段名称,才能copy回VS。不过除非VS集成linqpad,或者linqpad以VS插件的形式出现,否者这个功能是不好实现了。我原来用的是0.99版本,这次升级了新版,一定更加强大了。


Tired of querying in antiquated SQL?
Well, you don't have to!  LINQPad lets you interactively query SQL databases in a modern query language: LINQ.  Kiss goodbye to SQL Management Studio!

LINQPad supports everything in C# 3.0 and Framework 3.5:

  • LINQ to SQL
  • LINQ to Objects
  • LINQ to XML


LINQPad is also a great way to learn LINQ: it comes preloaded with 200 examples from my book, C# 3.0 in a Nutshell.  There's no better way to experience the coolness of LINQ and functional programming.

And LINQPad is more than just a LINQ query tool: it's a code snippet IDE. Instantly execute any C# 3 or VB 9 expression or statement block!

Best of all, LINQPad is free and needs no installation: just download and run.  The executable is only 2MB and is self-updating.

The LINQPad Challenge
If you think that you understand LINQ—or would like to—then I invite you to take the LINQPad Challenge.

The rules are simple:

Locate the shortcut for SQL Management Studio on your Start Menu and move it some place else.
In its place, insert a shortcut to LINQPad.
For the next week, perform all your ad-hoc SQL queries using only LINQPad.
At the end of the week, you will actually think in LINQ, rather than thinking in SQL and translating to LINQ.

LINQPad also allows old-fashioned SQL queries for tasks are genuinely impossible or clumsy in LINQ.  You'll feel an unpleasant sense of failure, though, should you cheat and use this feature frivolously!

If you can write all your ad-hoc queries in LINQ, you have a big head-start in C# 3.0 and LINQ.  And continued use of LINQPad will keep your LINQ knowledge alive—if you're not lucky enough to be using LINQ in your current projects.



                               
登录/注册后可看大图
回复  

使用道具 举报

2#
发表于 16-6-2008 13:01:43 | 只看该作者
挺不错的东西,还是免费的。谢谢提供信息。
回复  

使用道具 举报

3#
发表于 18-6-2008 15:38:14 | 只看该作者
LINQ是不是类SQL的语句,用于访问一些集合类型的数据?
回复  

使用道具 举报

您需要登录后才可以回帖 登录 | FreeOZ用户注册

本版积分规则

小黑屋|手机版|Archiver|FreeOZ论坛

GMT+10, 28-4-2024 09:09 , Processed in 0.035934 second(s), 18 queries , Gzip On, Redis On.

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表