| Thread | Last Post | Replies |
|
| SUM() problem | 18 Jul 2008 22:53 GMT | 6 |
I hope someone can help me with this newbie question: I have a table that contains a date (datetime) and a value (int). I would like to get the sum of all values between certain dates. Example: Date Value
|
| Stored Procedure with save document | 18 Jul 2008 21:42 GMT | 1 |
Any one know how to save any kind of documents in the stored procedure to SQL Server 2005? I knew how to do in asp.net web page or vb programming but this project using Power Builder (must too). I can call SQL Server stored procedure and let the stored procedure do the work for ...
|
| Select Case Statement Part 2 | 18 Jul 2008 21:01 GMT | 3 |
SQL 2005 Table = MoxyOrders Column = Limit In the Limit column this is the sort of data:
|
| Select Case Statement | 18 Jul 2008 20:27 GMT | 5 |
Can someone tell me why this simple Select Case is wrong. This is my first attempt at this. I'm doing this on SQL 2005. Works fine until I try to do a CASE. SELECT Case Limit
|
| Check before Insert | 18 Jul 2008 20:03 GMT | 6 |
I want to check to see if what I want to insert into a table already exists. I don't want to get an error. Just want to handle this gracefully. In my example below, even if it's a duplicate, it wouldn't make the entry as both CompanyID and AddressID are primary key fields but ...
|
| Trap when SELECT returns >1 row | 18 Jul 2008 19:50 GMT | 2 |
In my sproc, have a SELECT which should always return ONE row. However, I'd like to trap if returns zero rows or >1 row. How could I do this using TRY...CATCH ? Thanks
|
| Am I guaranteed that TRUNCATE TABLE always can be rolled back within a transaction? | 18 Jul 2008 19:37 GMT | 4 |
Is the statement below always true? I can use TRUNCATE TABLE as in the example below and I am guaranteed that if INSERT fails for some reason, table Result will be restored to its initial (before the
|
| Select returns no rows within TRY... END TRY | 18 Jul 2008 19:36 GMT | 4 |
I have this: BEGIN TRY SELECT @BankName = BankName, @BankRouting = BankRouting, @BankAccount = BankAccount, @BankAccountHolder = BankAccountHolder,
|
| join data from multiple tables with no keys | 18 Jul 2008 19:34 GMT | 1 |
In the database I am working out of there is one table (treatment_events) that collect the ids from other tables that are linked throught the application users use to enter the data. I cannot manually join these tables through using joins because they do not have related keys. The ...
|
| sql injection gibberish | 18 Jul 2008 19:11 GMT | 8 |
I'm finally winning against the script injection attacks. How can I convert the below gibberish into code I can understand? I'd like to know what they are throwin' at me. title=A&bt=1;DECLARE%20@S%20VARCHAR(4000) ...
|
| dynamic SQL and temp tables | 18 Jul 2008 17:38 GMT | 2 |
I'm doing that I thought would work but maybe not: trying to use dynamic SQL to create a temp table via SELECT / INTO. Here's a stripped-down version of my code: DECLARE @sql NVARCHAR(4000)
|
| CAST question | 18 Jul 2008 17:35 GMT | 2 |
I have a column that has batch numbers, but it's a varchar column "WHERE batch between 1500 and 1625" I need to find out if that batch numbers are between 1500 and 1625, however I'm getting an error:
|
| Dealing with multiple attributes that need to be searchable. | 18 Jul 2008 16:58 GMT | 31 |
I'm doing a school project and I'm supposed to be able to track campgrounds and their amenities. Here is some of the information I'm supposed to store: CAMPGROUND Number of Sites Number
|
| applications with Shared SQL users .. minimizing risk | 18 Jul 2008 16:28 GMT | 1 |
We installed this new Application.. The vendor insisted we use a common (single) SQL users for the ODBC dsn system entry.. Is there any way to enforce that this user/password is only used with that ODBC entry and not a a sql client.
|
| How do I handle a Transport Error | 18 Jul 2008 16:23 GMT | 1 |
I have a program that runs about 10 SQL statements (INSERT statements), each requiring about 2 hours. Sometimes I get a Transport Error and the program dies. I'm not sure how to handle this. In fact, I'm not sure what a transport error is, although I
|