| Thread | Last Post | Replies |
|
| Code for Scripts | 30 Jun 2005 21:40 GMT | 1 |
I'm looking for code that will create a script of a stored procedure vs. going through the gui. Can anyone help?
|
| Return Part of a text field | 30 Jun 2005 16:25 GMT | 2 |
I have a table with a field named "swNotes". The field type is ntext. The field can contain a variety of data. What I need to do is pull out just one particular piece. Here is an example of 4 different rows of data in the "swNotes" field:
|
| select most common value | 28 Jun 2005 23:15 GMT | 1 |
I am trying to create a list of the top 5 values in a column where I can select which top value I want. For example with values 1,1,2,3,3,3 I can select the 2nd most common value (which is 1).
|
| SQL and Grouping | 27 Jun 2005 18:56 GMT | 3 |
This should be simple but I just can't get it. Please Help! I have a table that contains hourly records, with a begin time and end time, and a value field. I need to group these so they are not hourly anymore. For example:
|
| Is Stored Procedure and 'in' broken in MSDE 2000/SQL 2000 SP4? | 27 Jun 2005 18:51 GMT | 1 |
This is not the command that im running but demonstrates the problem just fine, basically 'in' using statored procedures seems to be performing as 'in' or 'is' where as sending a query direct (identical) only performs 'in' as expected
|
| Insert non duplicate data | 25 Jun 2005 20:54 GMT | 1 |
I'm trying to construct an insert statement which will only insert data if it hasn't been inserted before in the same table, i.e. insert x,y into table where not exists (select x,y from table), or some such statement. Is there an easy way of doing this - maybe an if statement ...
|
| prompt for parameter in a view | 22 Jun 2005 16:33 GMT | 1 |
I would like to create a view that will prompt the user for a parameter. Much the same way a user can provide the paramenter for a query in Access. Seems like it should be simple, but I don't know how to do it. Any ideas?
|
| Query ... Distinct rows | 20 Jun 2005 19:55 GMT | 2 |
I have a table as follows ORDER_ID CODE STATUS 1000 XA3 5 1000 XA1 4
|
| Records Duplicating after a Join | 17 Jun 2005 22:07 GMT | 1 |
I have two tables as follows: Orders (ORDERID, CODE, ORDERQTY) and STOCK (CODE, LOCATION, STOCKQTY).
|
| Stored Procedure - Obtaining Output | 14 Jun 2005 20:13 GMT | 1 |
I would like to set up a stored procedure that does the following... - Check does a record exist in a table - Return the result (as True or False) My query is simply
|
| extreme help with query of 2 tables into 1 long table | 10 Jun 2005 22:54 GMT | 3 |
2 tables user id is key Table (A) 05_Users user_id | first_name |last_name|title|dept 64|John|Doe|director|cis
|
| using distinct on specific columns | 08 Jun 2005 20:45 GMT | 1 |
Is it possible to use the DISTINCT on specific columns? For instance: a table has ColA,ColB,ColC and I want my SELECT DISTINCT to focus on ColA and ColB but also return ColC. However, ColC is not part of the DISTINCT clause. Thanks
|
| filtering groups | 02 Jun 2005 21:05 GMT | 3 |
I need to write a query that will return the most recent incident within a related group, but I want a value returned for each instance of that group even if there's only one event recorded for them.
|
| Identity or Sequence column in non-table SELECT ? | 02 Jun 2005 21:05 GMT | 2 |
I'm looking for a way to specify a column in a SELECT statement that is a sequence number related to the record number in the result set. Ideally, just a number from 1 to N. Example:
|
| Rename a primary key column | 02 Jun 2005 08:16 GMT | 2 |
hi i am trying to rename a primary using sp_rename. but it keeps failing with message that the column is involved in dependencies. but i have already dropped all constraints on this table! any help please
|