Stored Procedures Questions


Scheduled job for Oracle 9 returning ORA-01858
We have an Oracle 9.2.0.1.0 database and get the ORA-01858: a non-numeric character was found where a numeric was expected error. Our production jobs are a series of stored procedures which are set up to run automatically by being called through another stored procedure, the Scheduler. While the Scheduler is running, two of them have [...]

Answer Question   |  August 4, 2010  3:05 PM
ORA-01858, Oracle 9, Oracle Scheduler, Stored Procedures
asked by:
190 pts.

How to create an SSIS package for importing an Access table to SQL Server, running SPs and exporting data to Excel
I need to create a SQL Server Integration Services (SSIS) package for importing an MS Access table into SQL Server, then running some stored procedures on this database and finally exporting the result to Excel. I am comfortable in writing queries and working in Management Studio but I don’t know how to actually design an [...]

Answer Question   |  April 9, 2008  11:30 PM
Microsoft Access, SQL Server integration/interoperability, SSIS, Stored Procedures
2,585 pts.

How can I collect database/server information across multiple MSSQL versions.
I would like to collect database info(backups, databases, logins, etc) as well as server information ( MSSQL version, patch level, etc). I would like to use one server to collect information from all of my servers. I have MSSQL 7, 2000, & 2005 on Windows servers 2000 & 2003. I am also new to MSSQL [...]

Answer Question   |  April 8, 2008  6:09 PM
Database, Scripting, SQL Server, Stored Procedures
asked by:
20 pts.

How can I take a backup of a SQL Server stored procedure only?
How can I take a backup of a SQL Server stored procedure only?

Answer Question   |  October 27, 2010  7:55 PM
SQL Server backup, Stored Procedures
2,585 pts.

Having problems converting SQL Server queries to stored procedures
I am using SQL Server queries as in-script and I have now decided to use the queries as stored procedures. However, I am facing some problems while converting the SQL Server queries into stored procedures. It’s a book search functionality based on book name and author name. My Old SQL query, which I was using [...]

Answer Question   |  March 22, 2008  8:38 PM
SQL Query, SQL Server, Stored Procedures
2,585 pts.

How do I move all stored procedures to a new SQL server?
I recently moved a database from SQL Server 2000 to a new server running SQL Server 2005. Is it possible to move all of the stored procedures to the new server?

Answer Question   |  March 22, 2008  7:01 PM
SQL Server 2000, SQL Server 2005, Stored Procedures
2,585 pts.

Stored Procedure Problem
Hi Greg, I am using SQL queries as in-script and now decided to use them as stored procedure. I am facing some problem while converting them into stored procedures. It’s a book search functionality based on book name and author name. My Old SQL query, which I was using with asp. SQL = “Select * [...]

Answer Question   |  March 21, 2008  3:34 PM
SQL, Stored Procedure variables, Stored Procedures
asked by:
5 pts.

SQL Stored Procedures
I am trying to return a count value from an SQL Stored Procedure in order to test if the record exists or not. I am calling the procedure from java as follows. CREATE PROCEDURE RTVSQL (IN LEVL CHARACTER(1), IN SYLL CHARACTER(4), INOUT FOUND INTEGER(2)) LANGUAGE SQL SELECT COUNT(*) INTO FOUND FROM EPYSTSTDTA/EPBSREP WHERE BSAICD = [...]

Answer Question   |  July 31, 2008  9:31 AM
SQL, Stored Procedures
asked by:
15 pts.

SQL Server – I would like a stored procedure that will take the name of a table as input.
I would like a stored procedure that will take the name of a table as input. What the procedure would do is drop all indexes on that table except any index that ends with U1 or P1, and save the information on the ones it drops. Then I would like another stored procedure that takes [...]

Answer Question   |  March 18, 2008  3:18 PM
SQL Server, SQL Server performance, Stored Procedures
2,585 pts.

How can I initialize arrays in stored procedures?
How can I initialize arrays in stored procedures?

Answer Question   |  March 16, 2008  10:20 PM
SQL Server, Stored Procedures
2,585 pts.

Passing a database name as a stored procedure parameter
I would like to be able to pass the name of a database as a parameter to a stored procedure. This db would be used for certain queries and may be different from the db where the stored procedure runs. Is it possible to specify a database name from within the T-SQL of the stored [...]

Answer Question   |  March 12, 2008  10:13 PM
Stored Procedures, T-SQL
2,585 pts.

How can I write a stored procedure to copy data from one database to another database on the same SQL Server, every weekend?
How can I write a stored procedure to copy data from one database to another database on the same SQL Server, every weekend?

Answer Question   |  March 5, 2008  11:39 PM
SQL Server, Stored Procedures
2,585 pts.

Equivolent SQL Server function for Access DoCmd.TransferText
I need to convert an Access app to SQL Server that has a DoCmd.Transfer command in it. Is there a qay to accomplish this in a stored procedure?

Answer Question   |  March 5, 2008  4:36 PM
DoCmd.Transfer, Microsoft Access, SQL Server, Stored Procedures
asked by:
15 pts.

Stored Procedure for dropping indexes
I would like a stored procedure that will take as input the name of a table. Whatthe procedure would do is drop all indexes on that table excpet any index that ends with U1 or P1, and save the information on the ones it drops. Then I would like another strored procedure that takes a [...]

Answer Question   |  March 3, 2008  4:04 PM
DROP, Indexes, Restore, Stored Procedures
asked by:
30 pts.

Msg 102, level 15, State 1, Line 102
I get this with an ‘Incorrect syntax’ messasge when I run a stored procedure. if I run the ‘offending’ code in isolation it works fine. If I tidy the code (e.g. remove line feeds etc), the error ‘moves’ to a different location. HELP!

Answer Question   |  January 22, 2010  12:55 PM
SQL Server, SQL Server errors, Stored Procedures
asked by:
5 pts.

Performance Tracking of Stored Procedures
we have a current system where a COBOL stored procedure is called by a .NET application. This COBOL SP then calls multiple COBOL subprograms which perform calculations and update files and then eventually return a value to the .NET app. We have a limitation in tracking the performance of each called subprogram, due to the [...]

Answer Question   |  February 27, 2008  7:07 PM
.NET applications, COBOL, COBOL stored procedures, CPU usage, MIPS, Performance management, Performance/Tuning, Stored Procedures
asked by:
5 pts.

SQL Command
I have created a stored procedure in SQL2000 like this : SELECT p.PO_code,p.Po_date, p.Supp_code + ‘ : ‘+ s.Sname as Supp_Nme,p.po_total,r.RC_code,r.Amount FROM PO_list p inner join RC_list r on r.PO_code = p.PO_code inner join Supplier s on s.supp_code = p.supp_code WHERE (p.Supp_code in (’102200′,’102083′)) and (substring(p.PO_CODE ,5,1) = ‘R’ ) and (p.cancel = ‘N’ and [...]

Answer Question   |  February 12, 2008  3:09 AM
SQL Server 2000, Stored Procedures, T-SQL
asked by:
50 pts.

Problems with sp_send_dbmail in SQL Server 2005
I am trying to convert my stored procedures in SQL 2005 from using xp_smtp_sendmail to using sp_send_dbmail. When I use the “Send Test Email” option in the management studio, I am getting the following error message from the sp_send_dbmail: The mail could not be sent to the recipients because of the mail server failure. (Sending [...]

Answer Question   |  February 22, 2008  5:32 PM
Sendmail, SQL Server 2005, Stored Procedures
asked by:
1,740 pts.

iseries stored procedure : read character string containing single apostrophe …. ex: Let’s
I am working on a stored procedure that requires a literal string to be input into a VARCHAR(1024) variable. My stored procedure has no problem reading the word……….. Let”s However, if I try to read the word…………Let’s, I get a code violation. Do I need to read the string as a datatype which does not [...]

Answer Question   |  March 7, 2010  11:04 PM
iSeries, Programmers, Stored Procedures
asked by:
5 pts.

MSSQL Stored Procedures
So im in my first year as a programming student and im stumped on a database i need to go alongside its stored procedures. Sorry beforehand if my english isnt that great,its not my native language.Anyways the database(tables) goes like this: Customers(CID,Name,LastName,Telephone) CID being the key. Plans(PID,CID,Descryption)CID being the key. DebitMovements(DMID,PID,Date,Amount)DMID and PID being keys. [...]

Answer Question   |  December 11, 2007  10:50 AM
SQL, SQL Server, Stored Procedures
asked by:
5 pts.