ireport stored procedure call mssql

I have an interesting issue, I need to pass 3-6 parameters to a stored procedure in a MsSQL database from a sh script on a Sun server and I need the output from this stored procedure in a file on the Sun server.There are numerous ways to do this, I'm sure, does anyone recognize the terrain ?Extra po ...

I'm trying to create a stored procedure in MSSQL Server 2005 that'll perform the following jobs:1) Create a login.2) Create an user in TestDB database for the login created in step 1.3) Assign the role 'db_generaluser' to the user created in step 2.The login name and password for the login to be cre ...

i have a stored procedure in MSSQL which needs to be migrated to oracle 10g,i have got problem related to migration.My mssql stored procedure is like as follows:create procedure sample(var1 varchar(20),var2 varchar(20) )asdeclare @V_TBL table(col1 varchar(20), col2 varchar(20))begininsert into @V_TB ...

What will be the equivalent stored procedure in DB2 for the following MSSQL7 SP.The migration tool does not translate it properly.CREATE PROCEDURE selectTasks@USER_ID int,@ROWLIMIT int = 10ASset rowcount @ROWLIMITSELECT TASK_IDFROM TASKSWHERE TASKS.USER_ID = @USER_IDORDER BY TIME Thank you in advanc ...

i have some troubles working with php+mssql ....my problem is : 1) call select statement2) call stored procedure statement1 and 2 i call one by one......for example when i am using this method...... (method_1)===========================================$result_set1 = $mssqlconnection->EXECUTE( ...

Hi, I'm a complete novice at PHP and SQL. I'm trying to get data put into a form to be entered into a mssql database table. I didn't write this code from scratch (someone sent it to me and I've changed the fields/variables, etc.), and I really can't troubleshoot beyond the absolute, bare basics. Any ...

I have Mac-mini running a small corporate intranet site, I have installed PHP 5 with FreeTDS so that I can access MSSQL databases that run on other company servers. My problem is that I want I have a search form that queries a database fine, but I have a stored procedure that modifies the input on o ...

please help for MsSQL stored procedure for ASP.net/C#. Inside stored procedure i used 4 different statements in where clause . first one is working but last 3's are not . Statements are given below-FILENAME LIKE ''%'+ @FILENAMETEXT +'%'' FILENAME LIKE '+ @FILENAMETEXT +'%'' SUBSTRING(FILENAME,1,4)=' ...

I am having problems returning a SQL Server text field from a SELECT statement in a stored procedure. In my CRecordset derived class I use the RFX_LongBinary call to retrieve the text data. However, when I open the recordset an error "Result not returned from a SELECT statement". I'm not s ...

Does anyone know if MSSQL stored procedure can return a string? As far as I know a stored procedure can only return an integer that tells whether the stored procedure fails or not. What I want to do is to use two stored procedures - one calls the other procedure, that returns a string to the calling ...

Alright. Right now, I'm working on a Register script. The POST data, and stuff like that works fine, it's only the Stored Procedure that's bothering me. Everytime I "attempt to register", it comes up with the error: Warning: mssql_execute() [function.mssql-execute]: stored procedure execut ...

I have stored procedure with couple input parameters (MS SQL) which creates temporary table and returns recordset as the result from that tamporary table. Stored procedure works ok on its own.I need to get that recordset in ASP but it doesn't work !?!Set cmd = Server.CreateObject("ADODB.Command ...

I'm running a stored procedure that is supposed to make an insert and return an output param with ADO from C++. The update is performed, but the output parameter comes out VT_NULL every time. (I've also tried return value and a select after the update, both returned a null) After days of trying to f ...

i'm utterly baffled as to how to get a stored procedure to function under php4 on a windows2000/apache box.i'm connecting to the db succesfully, however any attempts to execute a stroed procedure fail. any ideas.i have tried several approaches:$conn=mssql_connect("server","un", ...

I have an MS SQL Server stored procedure that I need to convert to Oracle. Most of it is ok but it uses a TABLE data type, what would the equivalent be in Oracle?Here is an example of the stored procedure:CREATE PROCEDURE AWSP_REMOVECOMPLETEDJOBS @DateFrom datetime,@DateTo datetimeAS --First grab th ...

this be my first post to these forums. I have already posted this question on a microsoft msdn forum, until someone advised that I ask my question here - dunno why I didnt think of that! Im working with an Oracle 10g Database from an ASP.NET 2.0 application, and want to know if it Oracle supports OP ...

Hey, i run a stored procedure from php that returns results into variables but when i write these variables to textboxes it only writes the first word and nothing after a space, how can i get it to show the whole string sent back by the stored procedure?//binds the variablemssql_bind($sp,"@user ...

I'm new to DB2. I need to create a physical table in my stored procedure. I cant use the session.temp table. how can i do it in my stored procedure. And also how can I create the physical table into a different database? For example i have 2 database. database1 and database2. my Stored proc is in da ...

I'm relatively new to stored procedure writing. My situation is an ASP page allowing multiple selections from a <select> option passing 1 to x number of options to a stored proc. for the WHERE clause.For instance, a user selects 1,3,5 and 6. These would need to be passed to the sp and then:... ...

I am trying to create a database within a stored procedure, so that the database name is generated each time. Please review the attached code, as sql seems to error out on '@dname'select @iStatus = 0select @dbname = 'offline' + '_' + convert(char(6),getdate(),112)create database @dbnameon( name = @d ...

Hai..I have data in text files ( not in csv format but in a properitary format).My requirment is to read the text files and parse it into corresponding data and then store it into the MSSQL Server Database.Is there any way to do this by using Stored Procedure or extended stored prodcedure in SQL Ser ...

I need to export data, from within a MSSql stored procedure to excel. Right now we use DTS, but its cumbersome and the users always screw it up.I would usually just send the tabel to a .csv fiel and pick it up in excel, but I have a field that has preceding zeros and excel truncates them and uses a ...

I am fairly new to MSSQL. Looking for a answer to a simple question. I have a application which passes in lot of stuff from the UI into a stored procedure that has to be inserted into a MSSQL 2005 database. All the information that is passed will be spilt into 4 inserts hitting 4 seperate tables. Al ...

I'm a newbie in MySQL. My system supports Oracle, JavaDB & MSSQL so I use sqlDeveloper for SQL statements. I wrote a simple stored procedure which receives an INTEGER and returns a result set. When running it from MySQL Query Browser the result set is returned just fine, but when running it from ...

I am using MSSQL 2005(SP 3). Is it possible to bind the parameters of a stored procedure using "bcp_bind" API? I just want to bind the in-memory buffers to the stored procedure parameters (STP will simply insert the data i.e params into the table). So that, when I call "bcp_sendrow ...

I got a database in MS SQL 2000 that needs to be converted temporarily to MSSQL 2008 (year 2011) that will then be converted to PostgreSQL in the beginning of 2012. There is a DTS package in MSSQL 2000 that pumps data from a third party helpdesk request software (BMC Remedy) to a temp table in MSSQL ...

I hope someone can help me out of here. I have to migrate from MSSQL2000 to Oracle 9x. On MSSQL I have a Stored Procedure that returns one Recordset. The Procedure calls itself many times (recursive) and the results are stored in a temporary table. At the end the procedure returns only the temporary ...

Im in the process of writing a java code to execute sp_sysmon .But i use callable statement to execute this stored procedure it says the query doent return resultset.How can i access result of this stored procedure.also is there is any table or stored procedure in sybase to get performance details l ...

I need to call a stored procedure in php to a mssql database. The stored procedure does not return a recordset but I need to read one of the out values. The following vb script works (not complete code) and msgbox's me the right value:<--snip-->Set tx = cmd.Parameters("@p_claimtype") ...

I have a weird problem.I constuct a query to call a stored procedure with some parameters, and the stored procedure is for inserting data into the db (into a couple of tables)When I send this to the SQL Server (MSSQL), using ODBC or the mssql_ calls, the record does not always get inserted (works 20 ...

I'm migrating a webapp from MSSQL to Postgresql and I'm having some problems with the store procedure. This is what I have so far, but it doesn't seem to be working. I'm getting an error that says ERROR: parser: parse error at or near "INTO" at character 9What I need to do1.) Get the visit ...

Is there a way to assign a default value to a column from the result of a stored procedure? Example: I have two servers using merge replication in MSSQL and I have a stored procedure that determines what server the record is being inserted into and assigns the next odd or even number respectively. I ...

I want to log the error to a table when error occurred, in MSSQL, I can use OBJECT_NAME(@@PROCID) to get the current stored procedure name in each stored procedure, but can anyone tell how to implement this function in MySQL? ...

I am using PHP 5.1.6 on a Linux server and need to access a MS SQL Server 2005 database. The PHP docs at http://us2.php.net/manual/en/ref.mssql.php say installing FreeTDS is a requirement for using the mssql extensions.FreeTDS is installed and configured for connection to a MS SQL 2005 server on my ...

I have the following stored procedure call working fine with MSSQL and Windows. But now I am trying to use the same logic with odbc_connect from a Linux box to a SQL database. I think instead of mssql_execute I need to use obdc_execute, but I don't know how to change the rest of this statement to wo ...

first off I'd like to state that I am pretty new to ms sql and stored procedures tho I have worked with sql for quite some time.My employer would like me to write a script which takes html content from a mssql db (originally delivered dynamically) and create static pages from them and also would lik ...

I have a stiored procedure in MSSQL 7 that I access with a CRecordset derived class. The stored procedure has two select statements. CRCREATE PROCEDURE getlistoftopjobs .........asSELECT ......do something elseSELECT ......... The recordset always uses the first result set. Even when the column sele ...

I'm having problems executing a MSSQL 7.0 stored procedure from C++ ODBC. I have followed the syntax but I still get an error.Here is the call:{? = CALL csp_getContentInfo;1 (?)}When I view the (Profiler) trace of the call it looks like this:declare @P3 intset @P3=NULLexec sp_executesql N'= CALL csp ...

I'm not sure what I'm doing wrong here... I have a COM object that I'm calling in an extended stored procedure. When I tested the COM in an .exe it worked with no problems, but when I call it from the stored procedure I get a message box that says:Microsoft Visual C++ Runtime LibraryRuntime Error!Pr ...

I have created a stored procedure which first creates an temporary table, insert the values and queries it. This works perfectly in MSSQL management studio, but when i try to execute the same procedure using php, it does not returns any rows.I am using PEAR DB and MSSQL 2005$sql="Exec up_parmse ...