Generally, it’s better to be explicit, so Select col1, col2 from Table
is better. The reason being that at some point, an extra column may be added to that table, and would cause unneeded data to be brought back from the query.
This isn’t a hard and fast rule though.
More Related Contents:
- How to store a list in a column of a database table
- Linq version of SQL “IN” statement
- How can you handle an IN sub-query with LINQ to SQL?
- LINQ to SQL query using “NOT IN”
- Linq to SQL: How do I stop the auto generated object name from being renamed?
- SQL Data models
- How to randomly select rows in SQL?
- What’s the difference between TRUNCATE and DELETE in SQL
- SQL to LINQ with multiple join, count and left join
- SQL best practice to deal with default sort order
- Entity Framework VS LINQ to SQL VS ADO.NET with stored procedures? [closed]
- How can I get column names from a table in Oracle?
- single fixed table with multiple columns vs flexible abstract tables
- How can I send email from PostgreSQL trigger?
- How to design a database for User Defined Fields?
- How to delete Duplicates in MySQL table
- Normalization in plain English
- Core Data Performance with Single Parent Entity
- Oracle – How to create a materialized view with FAST REFRESH and JOINS
- MySQL – how to front pad zip code with “0”?
- Oracle (Old?) Joins – A tool/script for conversion?
- How can I implement SQL INTERSECT and MINUS operations in MS Access
- Postgres Error: More than one row returned by a subquery used as an expression
- Does ‘Select’ always order by primary key?
- How do I create and query linked database servers in SQL Server?
- The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions
- Should I commit or rollback a read transaction?
- Why are foreign keys more used in theory than in practice?
- Entity Framework Skip/Take is very slow when number to skip is big
- What is difference between foreign key and reference key?