Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ORACLE vs SQL Server ! no parameter in scripts ?

Status
Not open for further replies.

mooki

Programmer
Aug 1, 2000
32
0
0
IL
I need to insert specific value into table but to get it from the user.<br><br>in Oracle for exp, i could use the &quot;&&quot; (umpersand) and when running it would ask me for the parameter value ! <br><br>is there anything similar in sqlserver ? <br>even transfering from Dos batch file using the osql....<br>somthing ????<br>
 
I'm going to give a somewhat ignorant answer, because I'm not an Oracle guru:<br><br>The closest thing would be the &quot;?&quot; bind parameter, but that's really for ODBC, not the server.<br><br>Frankly, I find the Oracle feature pretty odd.&nbsp;&nbsp;The database server is just that; there is no user interface per se.&nbsp;&nbsp;Yes, there's Query Analyzer, but I don't think that's intended by MS to be anything other than an ad-hoc and maintenance front-end, not a production application environment. <p>Robert Bradley<br><a href=mailto: > </a><br><a href= - Visual FoxPro Development</a><br>
 
I had this exact problem with a project I worked on.&nbsp;&nbsp;Had to write scripts for both Oracle and SQL Server and allow the user to pass in variable parameters.&nbsp;&nbsp;The best I've been able to do for for SQL Server is to write a stored procedure that takes in the variable parameter.&nbsp;&nbsp;Then use isql to execute the stored procedure passing the parameter through the RUN command line.&nbsp;&nbsp;The user can modify the run command to enter the correct parameter.&nbsp;&nbsp;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top