prevent ad-hoc queries?1862 (11/16/2009 8:58:36 PM) NeilI think I already know the answer to this question, but is there a way to
prevent users from issuing ad-hoc queries via Query Analyzer, Management
Studio or some other query tool? I want their access to da...
Order By and unions6777 (11/16/2009 7:26:55 PM) tshadI have the following statement which puts all the rows that have a length of
14 first and all other next. But I want to sort the top select in ascending
order and the bottom half in descending order. I kno...
select First(...11091 (11/16/2009 8:32:13 PM) StephI have a table (tbl_work) which contains these fields
Work_id (Primary Key)
Opportunity_id (Foreign Key)
Work_description
Work_type_code
Work_dt
State_id
I want to create a view with this result:
Wo...
ALTER SCHEMA problem41040 (11/16/2009 4:38:17 PM) JPK
I create a new Schema OS, and then try to move a dbo table (Address) over to
the new Schema
ALTER SCHEMA OS TRANSFER dbo.Address
Cannot alter the schema 'OS', because it does not exist or you do not h...
Binary Data2817 (11/16/2009 3:25:18 PM) shapperHello,
I need to save some resources on a database. The resource can be
simply:
Text, Html code, Sound file, Image file, etc.
I will not have a lot of resources. 100 max. But of various types.
It can b...
Usage (scope) of ALTER TABLE in sproc0910 (11/16/2009 2:10:00 PM) Stefanhi @ll,
I have a question about the usage of ALTER TABLE in a stored procedure
(SQL Server 2005):
First concurrent query, started first, should be later encapsulated in a
stored procedure:
BEGIN TR...
SQL 2008 intellisense errors Invalid Object01129 (11/16/2009 1:59:01 PM) Utf3 days ago I switched out my old SQL 2005 (SQL_Latin1_General_CP1_CI_AS)
server for a new one with SQL 2008(SQL_Latin1_General_CP1_CI_AS). I created
the Linked Server to my second server that runs SQL 2005...
Validation Duplicate2561 (11/13/2009 4:49:47 AM) WanHi Group,
I'm trying to identify duplicate information entered in couple of
fields. For eg., box table
have varchar fields =91old/new tag #s=92 as well as =91old/new item
number=92. These boxes are tie ...
Strange perfomance on count witn group by12931 (11/14/2009 12:28:01 PM) MichaelHello all
I've got a table without indexes about 1,300,000 records. Say, the structure
of table is:
create table T(A int, B int, C int)
The expression like
select count(*) from (select A, B, D = m...
Formatting a date2696 (11/15/2009 10:47:01 AM) UtfHello,
When I want to format a date in a view, I use e.g.
CONVERT(Char(20), tblPE_Personen.PE_Geboortedatum, 112)
With the CONVERT function, I am limited to the available Date and Time Styles.
How can I...
HOW TO PRODUCE LIGHT {Noor(Divine Energy)} IN YOUR HEART.0701 (11/15/2009 11:44:07 AM) fahadThe method of producing light.{NOOR}
NO MATTER ANY RELIGION - ALLAH(GOD) IS FOR EVERY ONE.
In prehistoric times stones would be rubbed together to make
fire.
Whereas a spark can also be produced by rubb...
SQL Subquery/Temp Value6784 (11/14/2009 4:13:26 PM) MSI'm creating a tempval, from this value I use it in the next select query
but I receive an error:
Conversion failed when converting the varchar value 'Select ColumnID1 from
dbo.tbl_main where id = ' to d...
do not display the result of a SELECT21532 (11/13/2009 10:39:27 PM) StefanHi,
For performance issues, we want to do several SELECT statements on
tables, in order to load theirs leafs in memory.
So everything goes fine, except that the result of the SELECT are in
log files, whic...
Reference temporary table twice41140 (11/13/2009 10:39:17 PM) richardI'm trying to temporary table inside a stored procedure, which might
be constructed in two entirely different ways, according to the
parameters passed to the procedure.
Using Northwind, my problem is illus...
generate summary row question2580 (11/13/2009 10:17:05 PM) FarmerThis is a multi-part message in MIME format.
------=_NextPart_000_0056_01CA6485.1F9AFF40
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Having this data set...
Need advice on product specs table2721 (11/13/2009 1:21:02 AM) UtfHi,
I'm trying to figure the best way to store product specs data e.g.
dimensions, weight, power requirements, etc.
Because the database will contain a wide variety of products and in time,
there will...
Select count of columns with data1564 (11/13/2009 7:35:06 PM) boat73I have a table that has 6 columns lets say Column1, Column2, Column3,
Column4, Column5, Column6 running on MSSQL 2008. What I need to do is
return how many of the coluns in a query contain data.
ex: select...
Three-Tier System Architecture, XML and SQLServer2005/200811179 (11/13/2009 3:36:05 PM) UtfIn the SQLServer 2000 BOL, "Three-Tier System Architecture" section depicts
pictorially the role played by the 3 layers. Is there a similar diagram for
SQLServer 2008?
...
Quicked way to create a copy of a table with all default values in101049 (11/13/2009 2:49:01 PM) UtfI know that using something like this is the quickest way to create a table:
SELECT * INTO newtablename FROM oldtablename WHERE 1>2
However I need for the new table to have all the default values that have ...
rolling back / undoing an update task1641 (11/12/2009 11:05:24 PM) NetI accidentally used this statement when trying to set my 'names'
column all to lower case in the away condition:
update mytable set names = lower('names') where home = 'away'
...as this changed all the n...